Commit f34f38bc authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

nsiproxy: Don't use long types in internal structure / helpers.

parent 4defa8d4
......@@ -446,9 +446,9 @@ static void ifinfo_fill_entry( struct if_entry *entry, NET_LUID *key, struct nsi
}
}
static NTSTATUS ifinfo_enumerate_all( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS ifinfo_enumerate_all( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count )
{
struct if_entry *entry;
DWORD num = 0;
......@@ -483,9 +483,9 @@ static NTSTATUS ifinfo_enumerate_all( void *key_data, DWORD key_size, void *rw_d
return status;
}
static NTSTATUS ifinfo_get_all_parameters( const void *key, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size )
static NTSTATUS ifinfo_get_all_parameters( const void *key, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size )
{
struct if_entry *entry;
NTSTATUS status = STATUS_OBJECT_NAME_NOT_FOUND;
......@@ -547,8 +547,8 @@ static NTSTATUS ifinfo_get_static_parameter( struct if_entry *entry, void *data,
return STATUS_INVALID_PARAMETER;
}
static NTSTATUS ifinfo_get_parameter( const void *key, DWORD key_size, DWORD param_type,
void *data, DWORD data_size, DWORD data_offset )
static NTSTATUS ifinfo_get_parameter( const void *key, UINT key_size, UINT param_type,
void *data, UINT data_size, UINT data_offset )
{
struct if_entry *entry;
NTSTATUS status = STATUS_OBJECT_NAME_NOT_FOUND;
......@@ -578,8 +578,8 @@ static NTSTATUS ifinfo_get_parameter( const void *key, DWORD key_size, DWORD par
return status;
}
static NTSTATUS index_luid_get_parameter( const void *key, DWORD key_size, DWORD param_type,
void *data, DWORD data_size, DWORD data_offset )
static NTSTATUS index_luid_get_parameter( const void *key, UINT key_size, UINT param_type,
void *data, UINT data_size, UINT data_offset )
{
struct if_entry *entry;
NTSTATUS status = STATUS_OBJECT_NAME_NOT_FOUND;
......
......@@ -30,7 +30,7 @@ struct icmp_send_echo_params
{
SOCKADDR_INET *dst;
void *request, *reply;
DWORD request_size, reply_len;
UINT request_size, reply_len;
BYTE bits, ttl, tos;
HANDLE handle;
};
......@@ -38,27 +38,27 @@ struct icmp_send_echo_params
/* output for IOCTL_NSIPROXY_WINE_ICMP_ECHO - cf. ICMP_ECHO_REPLY */
struct icmp_echo_reply_32
{
ULONG addr;
ULONG status;
ULONG round_trip_time;
UINT addr;
UINT status;
UINT round_trip_time;
USHORT data_size;
USHORT num_of_pkts;
ULONG data_ptr;
UINT data_ptr;
struct
{
BYTE ttl;
BYTE tos;
BYTE flags;
BYTE options_size;
ULONG options_ptr;
UINT options_ptr;
} opts;
};
struct icmp_echo_reply_64
{
ULONG addr;
ULONG status;
ULONG round_trip_time;
UINT addr;
UINT status;
UINT round_trip_time;
USHORT data_size;
USHORT num_of_pkts;
ULONGLONG data_ptr;
......
......@@ -111,8 +111,8 @@
WINE_DEFAULT_DEBUG_CHANNEL(nsi);
static NTSTATUS tcp_stats_get_all_parameters( const void *key, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size, void *static_data, DWORD static_size )
static NTSTATUS tcp_stats_get_all_parameters( const void *key, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size, void *static_data, UINT static_size )
{
struct nsi_tcp_stats_dynamic dyn;
struct nsi_tcp_stats_static stat;
......@@ -322,7 +322,7 @@ failed:
return NULL;
}
DWORD find_ipv6_addr_scope( const IN6_ADDR *addr, const struct ipv6_addr_scope *table, unsigned int size )
UINT find_ipv6_addr_scope( const IN6_ADDR *addr, const struct ipv6_addr_scope *table, unsigned int size )
{
const BYTE multicast_scope_mask = 0x0F;
const BYTE multicast_scope_shift = 0;
......@@ -514,10 +514,10 @@ unsigned int find_owning_pid( struct pid_map *map, unsigned int num_entries, UIN
#endif
}
static NTSTATUS tcp_conns_enumerate_all( DWORD filter, struct nsi_tcp_conn_key *key_data, DWORD key_size,
void *rw, DWORD rw_size,
struct nsi_tcp_conn_dynamic *dynamic_data, DWORD dynamic_size,
struct nsi_tcp_conn_static *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS tcp_conns_enumerate_all( UINT filter, struct nsi_tcp_conn_key *key_data, UINT key_size,
void *rw, UINT rw_size,
struct nsi_tcp_conn_dynamic *dynamic_data, UINT dynamic_size,
struct nsi_tcp_conn_static *static_data, UINT static_size, UINT_PTR *count )
{
DWORD num = 0;
NTSTATUS status = STATUS_SUCCESS;
......@@ -741,9 +741,9 @@ static NTSTATUS tcp_conns_enumerate_all( DWORD filter, struct nsi_tcp_conn_key *
return status;
}
static NTSTATUS tcp_all_enumerate_all( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS tcp_all_enumerate_all( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count )
{
TRACE( "%p %d %p %d %p %d %p %d %p\n", key_data, key_size, rw_data, rw_size,
dynamic_data, dynamic_size, static_data, static_size, count );
......@@ -752,9 +752,9 @@ static NTSTATUS tcp_all_enumerate_all( void *key_data, DWORD key_size, void *rw_
dynamic_data, dynamic_size, static_data, static_size, count );
}
static NTSTATUS tcp_estab_enumerate_all( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS tcp_estab_enumerate_all( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count )
{
TRACE( "%p %d %p %d %p %d %p %d %p\n", key_data, key_size, rw_data, rw_size,
dynamic_data, dynamic_size, static_data, static_size, count );
......@@ -763,9 +763,9 @@ static NTSTATUS tcp_estab_enumerate_all( void *key_data, DWORD key_size, void *r
dynamic_data, dynamic_size, static_data, static_size, count );
}
static NTSTATUS tcp_listen_enumerate_all( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS tcp_listen_enumerate_all( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count )
{
TRACE( "%p %d %p %d %p %d %p %d %p\n", key_data, key_size, rw_data, rw_size,
dynamic_data, dynamic_size, static_data, static_size, count );
......
......@@ -83,9 +83,9 @@
WINE_DEFAULT_DEBUG_CHANNEL(nsi);
static DWORD udp_num_addrs( USHORT family )
static UINT udp_num_addrs( USHORT family )
{
DWORD endpoint_count = 0;
UINT endpoint_count = 0;
nsi_enumerate_all( 1, 0, &NPI_MS_UDP_MODULEID, NSI_UDP_ENDPOINT_TABLE,
NULL, 0, NULL, 0, NULL, 0, NULL, 0, &endpoint_count );
......@@ -93,8 +93,8 @@ static DWORD udp_num_addrs( USHORT family )
return endpoint_count;
}
static NTSTATUS udp_stats_get_all_parameters( const void *key, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size, void *static_data, DWORD static_size )
static NTSTATUS udp_stats_get_all_parameters( const void *key, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size, void *static_data, UINT static_size )
{
struct nsi_udp_stats_dynamic dyn;
const USHORT *family = key;
......@@ -145,7 +145,7 @@ static NTSTATUS udp_stats_get_all_parameters( const void *key, DWORD key_size, v
struct
{
const char *name;
DWORD *elem;
UINT *elem;
} udp_stat_list[] =
{
{ "Udp6InDatagrams", &in_dgrams },
......@@ -202,9 +202,9 @@ static NTSTATUS udp_stats_get_all_parameters( const void *key, DWORD key_size, v
return STATUS_NOT_SUPPORTED;
}
static NTSTATUS udp_endpoint_enumerate_all( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count )
static NTSTATUS udp_endpoint_enumerate_all( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count )
{
DWORD num = 0;
NTSTATUS status = STATUS_SUCCESS;
......
......@@ -22,10 +22,10 @@ NTSTATUS nsi_enumerate_all_ex( struct nsi_enumerate_all_ex *params ) DECLSPEC_HI
NTSTATUS nsi_get_all_parameters_ex( struct nsi_get_all_parameters_ex *params ) DECLSPEC_HIDDEN;
NTSTATUS nsi_get_parameter_ex( struct nsi_get_parameter_ex *params ) DECLSPEC_HIDDEN;
static inline NTSTATUS nsi_enumerate_all( DWORD unk, DWORD unk2, const NPI_MODULEID *module, DWORD table,
void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size, void *static_data, DWORD static_size,
DWORD *count )
static inline NTSTATUS nsi_enumerate_all( UINT unk, UINT unk2, const NPI_MODULEID *module, UINT table,
void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size, void *static_data, UINT static_size,
UINT *count )
{
struct nsi_enumerate_all_ex params;
NTSTATUS status;
......@@ -54,7 +54,7 @@ static inline NTSTATUS nsi_enumerate_all( DWORD unk, DWORD unk2, const NPI_MODUL
BOOL convert_luid_to_unix_name( const NET_LUID *luid, const char **unix_name ) DECLSPEC_HIDDEN;
BOOL convert_unix_name_to_luid( const char *unix_name, NET_LUID *luid ) DECLSPEC_HIDDEN;
static inline BOOL convert_luid_to_index( const NET_LUID *luid, DWORD *index )
static inline BOOL convert_luid_to_index( const NET_LUID *luid, UINT *index )
{
struct nsi_get_parameter_ex params;
params.unknown[0] = 0;
......@@ -73,7 +73,7 @@ static inline BOOL convert_luid_to_index( const NET_LUID *luid, DWORD *index )
return !nsi_get_parameter_ex( &params );
}
static inline BOOL convert_index_to_luid( DWORD index, NET_LUID *luid )
static inline BOOL convert_index_to_luid( UINT index, NET_LUID *luid )
{
struct nsi_get_parameter_ex params;
params.unknown[0] = 0;
......@@ -95,11 +95,11 @@ static inline BOOL convert_index_to_luid( DWORD index, NET_LUID *luid )
struct ipv6_addr_scope
{
IN6_ADDR addr;
DWORD scope;
UINT scope;
};
struct ipv6_addr_scope *get_ipv6_addr_scope_table( unsigned int *size ) DECLSPEC_HIDDEN;
DWORD find_ipv6_addr_scope( const IN6_ADDR *addr, const struct ipv6_addr_scope *table, unsigned int size ) DECLSPEC_HIDDEN;
UINT find_ipv6_addr_scope( const IN6_ADDR *addr, const struct ipv6_addr_scope *table, unsigned int size ) DECLSPEC_HIDDEN;
struct pid_map
{
......@@ -112,16 +112,16 @@ unsigned int find_owning_pid( struct pid_map *map, unsigned int num_entries, UIN
struct module_table
{
DWORD table;
DWORD sizes[4];
NTSTATUS (*enumerate_all)( void *key_data, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size, DWORD_PTR *count );
NTSTATUS (*get_all_parameters)( const void *key, DWORD key_size, void *rw_data, DWORD rw_size,
void *dynamic_data, DWORD dynamic_size,
void *static_data, DWORD static_size );
NTSTATUS (*get_parameter)( const void *key, DWORD key_size, DWORD param_type,
void *data, DWORD data_size, DWORD data_offset );
UINT table;
UINT sizes[4];
NTSTATUS (*enumerate_all)( void *key_data, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size, UINT_PTR *count );
NTSTATUS (*get_all_parameters)( const void *key, UINT key_size, void *rw_data, UINT rw_size,
void *dynamic_data, UINT dynamic_size,
void *static_data, UINT static_size );
NTSTATUS (*get_parameter)( const void *key, UINT key_size, UINT param_type,
void *data, UINT data_size, UINT data_offset );
};
struct module
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment