From: Christian Grothoff Date: Sat, 21 Jan 2012 22:37:52 +0000 (+0000) Subject: -LRN: W32-pipes-are-overlapped-by-default-now X-Git-Tag: initial-import-from-subversion-38251~15176 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e8ee5c4c4069c159baabaa4071f066a7453e44c2;p=oweals%2Fgnunet.git -LRN: W32-pipes-are-overlapped-by-default-now --- diff --git a/src/util/disk.c b/src/util/disk.c index 1454a71b1..7ce4f5808 100644 --- a/src/util/disk.c +++ b/src/util/disk.c @@ -2181,10 +2181,13 @@ GNUNET_DISK_pipe (int blocking_read, int blocking_write, int inherit_read, int i BOOL ret; HANDLE tmp_handle; + /* All pipes are overlapped. If you want them to block - just + * call WriteFile() and ReadFile() with NULL overlapped pointer. + */ ret = create_selectable_pipe (&p->fd[0]->h, &p->fd[1]->h, NULL, 0, - blocking_read ? 0 : FILE_FLAG_OVERLAPPED, - blocking_write ? 0 : FILE_FLAG_OVERLAPPED); + FILE_FLAG_OVERLAPPED, + FILE_FLAG_OVERLAPPED); if (!ret) { GNUNET_free (p);