Improve handling of unidentified xattrs
Status from this message: Thanks, applied.
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/1 | erofs-utils: lib: actually skip the unidentified xattrslib/ | +3 | 1 reply |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/1] Improve handling of unidentified xattrs
Hi,
I had a report that when erofs is built from the btrfs filesystem with compression enabled, it would fail to build seemingly with error "failed to build shared xattrs". We tried to fix this by returning 0 (null) instead of error in parse_one_xattr(). However we need to actually skip it else we get a null pointer dereference in erofs_xattr_add() trying to process the same.
Thanks,
Sandeep.
Tested with btrfs with compression enabled.
$ lsattr mtpt/ --------c------------- mtpt/sample.txt
Before:
mkfs.erofs -z lz4hc,9 erofs.img mtpt/
mkfs.erofs 1.8.1-dirty
<W> erofs: parse_one_xattr() Line[285] skipped unidentified xattr: btrfs.compression Segmentation fault
After:
mkfs.erofs -z lz4hc,9 erofs.img mtpt/
mkfs.erofs 1.8.1-dirty
<W> erofs: parse_one_xattr() Line[285] skipped unidentified xattr: btrfs.compression Processing sample.txt ...
<W> erofs: parse_one_xattr() Line[285] skipped unidentified xattr: btrfs.compression Build completed.
------
Filesystem UUID: 9a1bb5a3-077a-40bc-972f-ed141059e7c8
Filesystem total blocks: 5 (of 4096-byte blocks)
Filesystem total inodes: 2
Filesystem total metadata blocks: 1
Filesystem total deduplicated bytes (of source files): 0
Sandeep Dhavale (1):
erofs-utils: lib: actually skip the unidentified xattrs
lib/xattr.c | 3 +++ 1 file changed, 3 insertions(+)
Signature · 1 line
2.46.0.184.g6999bdac58-goog