diff options
author | Werner Koch <[email protected]> | 2018-10-31 10:57:45 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2018-10-31 11:00:08 +0000 |
commit | 2e07d4f89a26bb56a55b2743d39fb37532028ffd (patch) | |
tree | 81e4f809896590e0f16dfdff2a0d84cb6ed2c791 /src | |
parent | docs: python docs restructure (diff) | |
download | gpgme-2e07d4f89a26bb56a55b2743d39fb37532028ffd.tar.gz gpgme-2e07d4f89a26bb56a55b2743d39fb37532028ffd.zip |
w32: Remove cruft in w32-io from WindowsME times.
* src/w32-io.c (set_synchronize): Remove.
(create_reader, create_writer): No need for set_synchronize.
--
The set_synchronize dates back to 2001 at a time when I wrote the
Windows support on WindowsME and Windows2000. Maybe this was required
then due to bugs in that old NT or partly NT based Windows versions.
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/w32-io.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/src/w32-io.c b/src/w32-io.c index 52327afa..aea0547e 100644 --- a/src/w32-io.c +++ b/src/w32-io.c @@ -247,33 +247,6 @@ get_desired_thread_priority (void) } -static HANDLE -set_synchronize (HANDLE hd) -{ -#ifdef HAVE_W32CE_SYSTEM - return hd; -#else - HANDLE new_hd; - - /* For NT we have to set the sync flag. It seems that the only way - to do it is by duplicating the handle. Tsss... */ - if (!DuplicateHandle (GetCurrentProcess (), hd, - GetCurrentProcess (), &new_hd, - EVENT_MODIFY_STATE | SYNCHRONIZE, FALSE, 0)) - { - TRACE1 (DEBUG_SYSIO, "gpgme:set_synchronize", hd, - "DuplicateHandle failed: ec=%d", (int) GetLastError ()); - /* FIXME: Should translate the error code. */ - gpg_err_set_errno (EIO); - return INVALID_HANDLE_VALUE; - } - - CloseHandle (hd); - return new_hd; -#endif -} - - static DWORD CALLBACK reader (void *arg) { @@ -470,7 +443,6 @@ create_reader (int fd) return NULL; } - ctx->have_data_ev = set_synchronize (ctx->have_data_ev); INIT_LOCK (ctx->mutex); #ifdef HAVE_W32CE_SYSTEM @@ -843,7 +815,6 @@ create_writer (int fd) return NULL; } - ctx->is_empty = set_synchronize (ctx->is_empty); INIT_LOCK (ctx->mutex); #ifdef HAVE_W32CE_SYSTEM |