Mail Archives: cygwin-developers/1998/09/21/06:20:35
On Sun, Sep 20, 1998 at 09:41:00PM +0400, Sergey Okhapkin wrote:
>Sergey Okhapkin wrote:
>> > -#define WINSOCK_FD_ZERO(set) ((set)->fd_count=0)
>> > +#define WINSOCK_FD_ZERO(set) memset ((set), 0, sizeof (*(set)))
>>
>> Hmmm... That works for me too! What is default structure members alignment for
>
>
>I've found the bug...
>
>--- /winsup/select.h Fri Sep 11 05:21:45 1998
>+++ select.h Sun Sep 20 20:37:17 1998
>@@ -16,7 +16,7 @@
> */
> typedef struct winsock_fd_set
> {
>- unsigned short fd_count;
>+ unsigned int fd_count;
> HANDLE fd_array[1024]; /* Dynamically allocated. */
> } winsock_fd_set;
That would do it. I've made this change and backed out my
(expensive) memset change.
Thanks.
--
cgf AT cygnus DOT com
http://www.cygnus.com/
- Raw text -