diff --git a/include/ntapi/nt_socket.h b/include/ntapi/nt_socket.h index 95f59e1..4b7e783 100644 --- a/include/ntapi/nt_socket.h +++ b/include/ntapi/nt_socket.h @@ -440,7 +440,8 @@ typedef int32_t __cdecl ntapi_sc_bind( typedef int32_t __cdecl ntapi_sc_listen( __in nt_socket * hssocket, - __in uintptr_t backlog, + __in uint32_t backlog, + __in uint32_t afdflags __optional, __out nt_io_status_block * iosb __optional); diff --git a/src/socket/ntapi_sc_listen.c b/src/socket/ntapi_sc_listen.c index 0fc0d87..efc9608 100644 --- a/src/socket/ntapi_sc_listen.c +++ b/src/socket/ntapi_sc_listen.c @@ -13,7 +13,8 @@ int32_t __cdecl __ntapi_sc_listen( __in nt_socket * hssocket, - __in uintptr_t backlog, + __in uint32_t backlog, + __in uint32_t afdflags __optional, __out nt_io_status_block * iosb __optional) { nt_afd_listen_info afd_listen; @@ -23,8 +24,8 @@ int32_t __cdecl __ntapi_sc_listen( /* afd_listen */ afd_listen.unknown = 0; - afd_listen.flags = 0; - afd_listen.backlog = (uint32_t)backlog; + afd_listen.flags = afdflags; + afd_listen.backlog = backlog; hssocket->iostatus = __ntapi->zw_device_io_control_file( hssocket->hsocket,