aboutsummaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-01-31 16:44:35 +0000
committerChristian Grothoff <christian@grothoff.org>2012-01-31 16:44:35 +0000
commit6325759d7b1d82acdc3ff5755eba661cc2533458 (patch)
treec1e5a65f8d40b54cbd35335425af230cc7d16f44 /src/util
parent6e841e9fac6d8a60a9f83933f1c3d9f4246d63ac (diff)
downloadgnunet-6325759d7b1d82acdc3ff5755eba661cc2533458.tar.gz
gnunet-6325759d7b1d82acdc3ff5755eba661cc2533458.zip
-fix for W32 pipes from bratao
Diffstat (limited to 'src/util')
-rw-r--r--src/util/disk.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/util/disk.c b/src/util/disk.c
index d64bcbafb..b2a705593 100644
--- a/src/util/disk.c
+++ b/src/util/disk.c
@@ -2142,8 +2142,16 @@ GNUNET_DISK_pipe (int blocking_read, int blocking_write, int inherit_read, int i
2142 fd); 2142 fd);
2143#else 2143#else
2144 struct GNUNET_DISK_PipeHandle *p; 2144 struct GNUNET_DISK_PipeHandle *p;
2145 struct GNUNET_DISK_FileHandle *fds;
2145 BOOL ret; 2146 BOOL ret;
2146 HANDLE tmp_handle; 2147 HANDLE tmp_handle;
2148
2149
2150 p = GNUNET_malloc (sizeof (struct GNUNET_DISK_PipeHandle) +
2151 2 * sizeof (struct GNUNET_DISK_FileHandle));
2152 fds = (struct GNUNET_DISK_FileHandle *) &p[1];
2153 p->fd[0] = &fds[0];
2154 p->fd[1] = &fds[1];
2147 2155
2148 /* All pipes are overlapped. If you want them to block - just 2156 /* All pipes are overlapped. If you want them to block - just
2149 * call WriteFile() and ReadFile() with NULL overlapped pointer. 2157 * call WriteFile() and ReadFile() with NULL overlapped pointer.