diff options
author | midipix <writeonce@midipix.org> | 2021-03-11 12:52:20 +0000 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2021-03-11 12:52:20 +0000 |
commit | a6f0774e52ad51b89c4c39e31b742c8e38d7008b (patch) | |
tree | bfc810c95849afcb5b5f2c7d6d5dd38a83f94a49 /src | |
parent | 97f3e567e0bb6e67472ff652f48d7442d8bdcdae (diff) | |
download | ntapi-a6f0774e52ad51b89c4c39e31b742c8e38d7008b.tar.bz2 ntapi-a6f0774e52ad51b89c4c39e31b742c8e38d7008b.tar.xz |
daemon routines: properly close the internal-client-ready event as needed.
Diffstat (limited to 'src')
-rw-r--r-- | src/daemon/ntapi_dsr_init.c | 1 | ||||
-rw-r--r-- | src/daemon/ntapi_dsr_internal_connection.c | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/daemon/ntapi_dsr_init.c b/src/daemon/ntapi_dsr_init.c index d74806d..20d7f87 100644 --- a/src/daemon/ntapi_dsr_init.c +++ b/src/daemon/ntapi_dsr_init.c @@ -175,7 +175,6 @@ int32_t __stdcall __ntapi_dsr_init(nt_daemon_params * params) if (params->flags & NT_DSR_INIT_CLOSE_EVENTS) { __ntapi->zw_close(params->hevent_daemon_port); __ntapi->zw_close(params->hevent_daemon_ready); - __ntapi->zw_close(params->hevent_internal_client_ready); } return NT_STATUS_SUCCESS;; diff --git a/src/daemon/ntapi_dsr_internal_connection.c b/src/daemon/ntapi_dsr_internal_connection.c index e440719..5301791 100644 --- a/src/daemon/ntapi_dsr_internal_connection.c +++ b/src/daemon/ntapi_dsr_internal_connection.c @@ -74,6 +74,9 @@ static int32_t __ntapi_dsr_internal_client_connect_impl(nt_daemon_params * param params->hevent_internal_client_ready, 0); + if (params->flags & NT_DSR_INIT_CLOSE_EVENTS) + __ntapi->zw_close(params->hevent_internal_client_ready); + /* exit the task-specific thread */ return __ntapi_dsr_internal_client_connect_exit( params,status); |