OSDN Git Service

ext4_utils: xattr_assert_sane false positives
authorMark Salyzyn <salyzyn@google.com>
Mon, 6 Apr 2015 19:16:42 +0000 (12:16 -0700)
committerMark Salyzyn <salyzyn@google.com>
Mon, 6 Apr 2015 19:20:54 +0000 (12:20 -0700)
commit636d848860e5eac4225a830706fc34d48d8cc01e
treef2b9f713779565e627f1149894284ad68ceccb79
parent01764adb2c182ef593fba3b9cdece112c26a4765
ext4_utils: xattr_assert_sane false positives

xattr_free_space() does not match kernel, it subtracts
sizeof(__u32) as a buffer zone to permit IS_LAST_ENTRY
to function. As documented in .../linux/fs/ext4/xattr.c:

+------------------+
| header           |
| entry 1          | |
| entry 2          | | growing downwards
| entry 3          | v
| four null bytes  | <<<< HERE is why sizeof(__u32)
| . . .            |
| value 1          | ^
| value 3          | | growing upwards
| value 2          | |
+------------------+

Change-Id: Iee6e4e90664a3c2c5056006870b0f2f22b236bad
ext4_utils/contents.c