projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
vfs: read file_handle only once in handle_to_path
[linux-2.6-microblaze.git]
/
fs
/
fhandle.c
diff --git
a/fs/fhandle.c
b/fs/fhandle.c
index
999ff5c
..
d59712d
100644
(file)
--- a/
fs/fhandle.c
+++ b/
fs/fhandle.c
@@
-195,8
+195,9
@@
static int handle_to_path(int mountdirfd, struct file_handle __user *ufh,
goto out_err;
}
/* copy the full handle */
- if (copy_from_user(handle, ufh,
- sizeof(struct file_handle) +
+ *handle = f_handle;
+ if (copy_from_user(&handle->f_handle,
+ &ufh->f_handle,
f_handle.handle_bytes)) {
retval = -EFAULT;
goto out_handle;