提交 850a496f 编写于 作者: A Al Viro

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: NAl Viro <viro@zeniv.linux.org.uk>
上级 9cb569d6
......@@ -104,7 +104,7 @@ static char *__dentry_name(struct dentry *dentry, char *name)
__putname(name);
return NULL;
}
strncpy(name, root, PATH_MAX);
strlcpy(name, root, PATH_MAX);
if (len > p - name) {
__putname(name);
return NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册