Message ID | CAOg9mSQU4q4hCB2WE6TjKPyoCkYPjTm+4kO=W5L2A7TKAxFGDw@mail.gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/fs/orangefs/xattr.c b/fs/orangefs/xattr.c index 1165047..bdb407e 100644 --- a/fs/orangefs/xattr.c +++ b/fs/orangefs/xattr.c @@ -97,7 +97,11 @@ ssize_t orangefs_inode_getxattr(struct inode *inode, const ch goto out_unlock; new_op->upcall.req.getxattr.refn = orangefs_inode->refn; - strcpy(new_op->upcall.req.getxattr.key, name); + + ret = snprintf((char *)new_op->upcall.req.getxattr.key, + ORANGEFS_MAX_XATTR_NAMELEN, + "%s", + name); /* * NOTE: Although keys are meant to be NULL terminated textual