[Bug 677827] New: setxattr(2) ignores XATTR_CREATE and XATTR_REPLACE
https://bugzilla.novell.com/show_bug.cgi?id=677827 https://bugzilla.novell.com/show_bug.cgi?id=677827#c0 Summary: setxattr(2) ignores XATTR_CREATE and XATTR_REPLACE Classification: openSUSE Product: openSUSE 11.3 Version: Final Platform: x86-64 OS/Version: openSUSE 11.3 Status: NEW Severity: Normal Priority: P5 - None Component: Kernel AssignedTo: kernel-maintainers@forge.provo.novell.com ReportedBy: torsten.foertsch@gmx.net QAContact: qa@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/534.23 SUSE/11.0.685.0 (KHTML, like Gecko) Chrome/11.0.685.0 Safari/534.23 all of the *setxattr syscalls ignore the flags parameter at least on ext4. If the attribute already exists and flags==XATTR_CREATE the syscall should fail according to the man page. But strace reports this: setxattr(".", "user.diino.size", "franz", 5, XATTR_CREATE) = 0 The same for XATTR_REPLACE, it should fail unless the attribute already exists. But: setxattr(".", "user.diino.sizevsfdbsg", "franz", 5, XATTR_REPLACE) = 0 According to the docs 0 means success. And the result also shows it: $ getfattr -d . # file: . user.diino.size="franz" user.diino.sizevafdv="frinz" user.diino.sizevsfdbsg="franz" user.hugo="fritz" Reproducible: Always Steps to Reproduce: 1. 2. 3. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c2
Jan Kara
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c3
--- Comment #3 from Jan Kara
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c4
--- Comment #4 from Jan Kara
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c5
Jan Kara
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c6
Swamp Workflow Management
https://bugzilla.novell.com/show_bug.cgi?id=677827
https://bugzilla.novell.com/show_bug.cgi?id=677827#c7
Swamp Workflow Management
participants (1)
-
bugzilla_noreply@novell.com