From: | Ranier Vilela <ranier(dot)vf(at)gmail(dot)com> |
---|---|
To: | Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Windows sockets (select missing events?) |
Date: | 2023-12-30 13:40:11 |
Message-ID: | CAEudQArx03C3x2UDKjTrknFsxYmx3Bu+A6yyi59y1NRFi2s3xQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Em qui., 28 de dez. de 2023 às 14:45, Ranier Vilela <ranier(dot)vf(at)gmail(dot)com>
escreveu:
> Hi,
>
> The type of field fd_count is defined in winsock.h:
> typedef unsigned int u_int;
>
> So in the struct fd_set,
> the field fd_count is unsigned int.
>
> The pgwin32_select function has loops that use *int* as indices.
>
> Question: in Windows, the socket select function isn't missing some events?
>
> If not, It would be a good prevention practice, using the correct type,
> right?
>
> Patch attached.
>
Fix overflow with patch.
best regards,
Ranier Vilela
Attachment | Content-Type | Size |
---|---|---|
v1-001-fix-socket-select-events.patch | application/octet-stream | 879 bytes |
From | Date | Subject | |
---|---|---|---|
Next Message | Pavel Luzanov | 2023-12-30 14:23:40 | Re: Things I don't like about \du's "Attributes" column |
Previous Message | Ranier Vilela | 2023-12-30 13:34:12 | Fix resource leak (src/bin/pg_combinebackup/pg_combinebackup.c) |