/*
This file is part of GNUnet.
- (C) 2009-2013 Christian Grothoff (and other contributing authors)
+ Copyright (C) 2009-2013 Christian Grothoff (and other contributing authors)
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
#ifdef WINDOWS
/**
- * Linked list of handles
+ * Array of file handles (from pipes) that are also in
+ * the FDSet. Needed as those cannot go into @e sds
+ * on W32.
*/
- struct GNUNET_CONTAINER_SList *handles;
+ const struct GNUNET_DISK_FileHandle **handles;
+
+ /**
+ * Size of the @e handles array
+ */
+ unsigned int handles_size;
+
+ /**
+ * Number of @e handles slots in use. Always
+ * smaller than @e handles_size.
+ */
+ unsigned int handles_pos;
+
#endif
};
const struct GNUNET_DISK_FileHandle *h);
+/**
+ * Add a file handle to the fd set
+ * On W32: ensure that the handle is first in the array.
+ *
+ * @param fds fd set
+ * @param h the file handle to add
+ */
+void
+GNUNET_NETWORK_fdset_handle_set_first (struct GNUNET_NETWORK_FDSet *fds,
+ const struct GNUNET_DISK_FileHandle *h);
+
+
/**
* Check if a file handle is part of an fd set
*