mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-03 07:38:10 +00:00
hostfs: dumb (and usually harmless) tpyo - strncpy instead of strlcpy
... not harmless in this case - we have a string in the end of buffer already. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
parent
9cb569d601
commit
850a496f96
1 changed files with 1 additions and 1 deletions
|
@ -104,7 +104,7 @@ static char *__dentry_name(struct dentry *dentry, char *name)
|
||||||
__putname(name);
|
__putname(name);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
strncpy(name, root, PATH_MAX);
|
strlcpy(name, root, PATH_MAX);
|
||||||
if (len > p - name) {
|
if (len > p - name) {
|
||||||
__putname(name);
|
__putname(name);
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Reference in a new issue