New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setxattr is broken #730
Labels
Comments
Thanks for the report! Pull requests are welcome :-). |
I can confirm the problem. It seems to affect only setxattr, not getxattr:
|
Reverting commit 7f430a3 fixes the problem (though it's not immediately obvious to me why). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Likely this commit:
7f430a3
The 'name' string passed to fs->op.setxattr has the first 8 characters missing. Using the 'passthrough' example, start it up and try:
setfattr -n user.myxattr -v myvalue /xmp/somefile
setfattr: /xmp/somefile: Operation not supported
This is because the string seen by xmp_setxattr() is "attr" instead of "user.myxattr".
To prove the name pointer is off by 8 bytes, inside xmp_setxattr() this works to change:
int res = lsetxattr(path, name, value, size, flags);
to
int res = lsetxattr(path, (char *)(name-8), value, size, flags);
The text was updated successfully, but these errors were encountered: