mirror of
https://github.com/topjohnwu/ndk-busybox.git
synced 2024-11-30 23:21:02 +00:00
unzip: fix regression on big-endian machines
This fixes a regression which was introduced with commit 2a0867a5
("unzip: optional support for bzip2 and lzma") and causes unzip to exit
with error when extracting archives:
unzip: unsupported method 2048
Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
5b3cbe3a53
commit
46f3f16b58
@ -114,6 +114,7 @@ typedef union {
|
||||
|
||||
#define FIX_ENDIANNESS_ZIP(zip) \
|
||||
do { if (BB_BIG_ENDIAN) { \
|
||||
(zip).fmt.method = SWAP_LE16((zip).fmt.method ); \
|
||||
(zip).fmt.crc32 = SWAP_LE32((zip).fmt.crc32 ); \
|
||||
(zip).fmt.cmpsize = SWAP_LE32((zip).fmt.cmpsize ); \
|
||||
(zip).fmt.ucmpsize = SWAP_LE32((zip).fmt.ucmpsize ); \
|
||||
|
Loading…
Reference in New Issue
Block a user