On Tue, 27 Jul 1999, Kurt Garloff wrote:
>--- fs/select.c.~1~ Wed Jul 14 19:09:30 1999
>+++ fs/select.c Tue Jul 27 00:25:47 1999
[..]
>@@ -268,8 +268,8 @@
> if (n < 0)
> goto out_nofds;
>
>- if (n > KFDS_NR)
>- n = KFDS_NR;
>+ if (n > current->files->max_fdset + 1)
>+ n = current->files->max_fdset + 1;
That should be:
if (n > current->files->max_fdset)
n = current->files->max_fdset;
>@@ -277,7 +277,7 @@
> * long-words.
> */
> ret = -ENOMEM;
>- size = FDS_BYTES(n);
>+ size = (n + 8 * sizeof(long) - 1) / (8 * sizeof(long)) * sizeof(long);
> bits = kmalloc(6 * size, GFP_KERNEL);
> if (!bits)
> goto out_nofds;
The change above is not necessary.
Andrea