From: Al Viro Date: Mon, 27 Aug 2012 00:41:49 +0000 (-0400) Subject: switch hpux_getdents() to fget_light() X-Git-Tag: Ubuntu-5.13.0-19.19~23731^2~32 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=ecaa80fbe589d2638b8a8a075916b1862a1124e2;p=mirror_ubuntu-jammy-kernel.git switch hpux_getdents() to fget_light() Signed-off-by: Al Viro --- diff --git a/arch/parisc/hpux/fs.c b/arch/parisc/hpux/fs.c index c71eb6c79897..41e01832cb21 100644 --- a/arch/parisc/hpux/fs.c +++ b/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; }