9468ea06d2
Add O_NOFOLLOW (and O_NOCTTY for good measure) to open calls like e2fsprogs does. In lsattr, when recursing, operate only on regular files, symlinks, and directories. (Otherwise, "lsattr /dev" can e.g. open a watchdog device... not good). At this time, looks like chattr/lsattr can't operate on symlink inodes - ioctls do not work on open(O_PATH | O_NOFOLLOW) fds. function old new delta lsattr_dir_proc 168 203 +35 change_attributes 410 408 -2 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 35/-2) Total: 33 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> |
||
---|---|---|
.. | ||
chattr.c | ||
Config.src | ||
e2fs_lib.c | ||
e2fs_lib.h | ||
fsck.c | ||
Kbuild.src | ||
lsattr.c | ||
README | ||
tune2fs.c |
Authors and contributors of original e2fsprogs: Remy Card <card@masi.ibp.fr> Theodore Ts'o <tytso@mit.edu> Stephen C. Tweedie <sct@redhat.com> Andreas Gruenbacher, <a.gruenbacher@computer.org> Kaz Kylheku <kaz@ashi.footprints.net> F.W. ten Wolde <franky@duteca.et.tudelft.nl> Jeremy Fitzhardinge <jeremy@zip.com.au> M.J.E. Mol <marcel@duteca.et.tudelft.nl> Miquel van Smoorenburg <miquels@drinkel.ow.org> Uwe Ohse <uwe@tirka.gun.de>