diff options
-rw-r--r-- | fs/select.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/fs/select.c b/fs/select.c index 071660fa7b01..fce0fd1bb1d1 100644 --- a/fs/select.c +++ b/fs/select.c | |||
@@ -310,7 +310,7 @@ static int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, | |||
310 | fd_set __user *exp, s64 *timeout) | 310 | fd_set __user *exp, s64 *timeout) |
311 | { | 311 | { |
312 | fd_set_bits fds; | 312 | fd_set_bits fds; |
313 | char *bits; | 313 | void *bits; |
314 | int ret, size, max_fdset; | 314 | int ret, size, max_fdset; |
315 | struct fdtable *fdt; | 315 | struct fdtable *fdt; |
316 | /* Allocate small arguments on the stack to save memory and be faster */ | 316 | /* Allocate small arguments on the stack to save memory and be faster */ |
@@ -341,12 +341,12 @@ static int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, | |||
341 | bits = kmalloc(6 * size, GFP_KERNEL); | 341 | bits = kmalloc(6 * size, GFP_KERNEL); |
342 | if (!bits) | 342 | if (!bits) |
343 | goto out_nofds; | 343 | goto out_nofds; |
344 | fds.in = (unsigned long *) bits; | 344 | fds.in = bits; |
345 | fds.out = (unsigned long *) (bits + size); | 345 | fds.out = bits + size; |
346 | fds.ex = (unsigned long *) (bits + 2*size); | 346 | fds.ex = bits + 2*size; |
347 | fds.res_in = (unsigned long *) (bits + 3*size); | 347 | fds.res_in = bits + 3*size; |
348 | fds.res_out = (unsigned long *) (bits + 4*size); | 348 | fds.res_out = bits + 4*size; |
349 | fds.res_ex = (unsigned long *) (bits + 5*size); | 349 | fds.res_ex = bits + 5*size; |
350 | 350 | ||
351 | if ((ret = get_fd_set(n, inp, fds.in)) || | 351 | if ((ret = get_fd_set(n, inp, fds.in)) || |
352 | (ret = get_fd_set(n, outp, fds.out)) || | 352 | (ret = get_fd_set(n, outp, fds.out)) || |