projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
601350f
)
ovl: fix format of setxattr debug
author
Miklos Szeredi
<
[email protected]
>
Thu, 4 Oct 2018 12:49:10 +0000
(14:49 +0200)
committer
Miklos Szeredi
<
[email protected]
>
Thu, 4 Oct 2018 12:49:10 +0000
(14:49 +0200)
Format has a typo: it was meant to be "%.*s", not "%*s". But at some point
callers grew nonprintable values as well, so use "%*pE" instead with a
maximized length.
Reported-by: Amir Goldstein <
[email protected]
>
Signed-off-by: Miklos Szeredi <
[email protected]
>
Fixes: 3a1e819b4e80 ("ovl: store file handle of lower inode on copy up")
Cc: <
[email protected]
> # v4.12
fs/overlayfs/overlayfs.h
patch
|
blob
|
history
diff --git
a/fs/overlayfs/overlayfs.h
b/fs/overlayfs/overlayfs.h
index f61839e1054c6b40872a6bf3dc89e3a7da7b6f52..a3c0d95843121e92a103a6b07628feb853c31399 100644
(file)
--- a/
fs/overlayfs/overlayfs.h
+++ b/
fs/overlayfs/overlayfs.h
@@
-152,8
+152,8
@@
static inline int ovl_do_setxattr(struct dentry *dentry, const char *name,
const void *value, size_t size, int flags)
{
int err = vfs_setxattr(dentry, name, value, size, flags);
- pr_debug("setxattr(%pd2, \"%s\", \"%*
s\"
, 0x%x) = %i\n",
- dentry, name,
(int) size, (char *) valu
e, flags, err);
+ pr_debug("setxattr(%pd2, \"%s\", \"%*
pE\", %zu
, 0x%x) = %i\n",
+ dentry, name,
min((int)size, 48), value, siz
e, flags, err);
return err;
}