Browse Source

switch hpux_getdents() to fget_light()

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro 13 years ago
parent
commit
ecaa80fbe5
1 changed files with 3 additions and 3 deletions
  1. 3 3
      arch/parisc/hpux/fs.c

+ 3 - 3
arch/parisc/hpux/fs.c

@@ -112,9 +112,9 @@ int hpux_getdents(unsigned int fd, struct hpux_dirent __user *dirent, unsigned i
 	struct file * file;
 	struct hpux_dirent __user * lastdirent;
 	struct getdents_callback buf;
-	int error = -EBADF;
+	int error = -EBADF, fput_needed;
 
-	file = fget(fd);
+	file = fget_light(fd, &fput_needed);
 	if (!file)
 		goto out;
 
@@ -134,7 +134,7 @@ int hpux_getdents(unsigned int fd, struct hpux_dirent __user *dirent, unsigned i
 			error = count - buf.count;
 	}
 
-	fput(file);
+	fput_light(file, fput_needed);
 out:
 	return error;
 }