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;
error = count - buf.count;
}
- fput(file);
+ fput_light(file, fput_needed);
out:
return error;
}