diff options
author | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-05-30 19:16:45 -0400 |
---|---|---|
committer | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-05-30 19:16:45 -0400 |
commit | ada47b5fe13d89735805b566185f4885f5a3f750 (patch) | |
tree | 644b88f8a71896307d71438e9b3af49126ffb22b /fs/file.c | |
parent | 43e98717ad40a4ae64545b5ba047c7b86aa44f4f (diff) | |
parent | 3280f21d43ee541f97f8cda5792150d2dbec20d5 (diff) |
Merge branch 'wip-2.6.34' into old-private-masterarchived-private-master
Diffstat (limited to 'fs/file.c')
-rw-r--r-- | fs/file.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -257,7 +257,7 @@ int expand_files(struct files_struct *files, int nr) | |||
257 | * N.B. For clone tasks sharing a files structure, this test | 257 | * N.B. For clone tasks sharing a files structure, this test |
258 | * will limit the total number of files that can be opened. | 258 | * will limit the total number of files that can be opened. |
259 | */ | 259 | */ |
260 | if (nr >= current->signal->rlim[RLIMIT_NOFILE].rlim_cur) | 260 | if (nr >= rlimit(RLIMIT_NOFILE)) |
261 | return -EMFILE; | 261 | return -EMFILE; |
262 | 262 | ||
263 | /* Do we need to expand? */ | 263 | /* Do we need to expand? */ |
@@ -478,7 +478,7 @@ repeat: | |||
478 | error = fd; | 478 | error = fd; |
479 | #if 1 | 479 | #if 1 |
480 | /* Sanity check */ | 480 | /* Sanity check */ |
481 | if (rcu_dereference(fdt->fd[fd]) != NULL) { | 481 | if (rcu_dereference_raw(fdt->fd[fd]) != NULL) { |
482 | printk(KERN_WARNING "alloc_fd: slot %d not NULL!\n", fd); | 482 | printk(KERN_WARNING "alloc_fd: slot %d not NULL!\n", fd); |
483 | rcu_assign_pointer(fdt->fd[fd], NULL); | 483 | rcu_assign_pointer(fdt->fd[fd], NULL); |
484 | } | 484 | } |