When xfsrestore reads its inventory from tape it fails to convert the media record on bigendian systems, if the online inventory is unavailable this results in invalid data being writen to the online inventory and failure to restore non-directory files. The series fixes the converstion and related issues. --- v2 - Seperate out cleanup and content.c changes, fix whitespace. - Show a full reproducer in the first patch. V3 - Fix whitespace and Signed-off-by. - Make for loop formatting consistent. - Rename patches to make their intent clearer. - Add xfsdump: fix on-media inventory stream packing. - Add descriptions that reproduce the stream problems. Donald Douwsma (4): xfsrestore: fix on-media inventory media unpacking xfsrestore: fix on-media inventory stream unpacking xfsdump: fix on-media inventory stream packing xfsrestore: untangle inventory unpacking logic inventory/inv_stobj.c | 42 +++++++++++++++--------------------------- restore/content.c | 13 +++++-------- 2 files changed, 20 insertions(+), 35 deletions(-) -- 2.31.1