aboutsummaryrefslogtreecommitdiff
path: root/system/xar/patches/xar-1.8-arm-ppc.patch
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2022-01-11 13:08:32 -0500
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2022-01-17 09:03:30 +0700
commit80ff04d62987392f2804cb137d108566d44a8ed1 (patch)
tree9de8c2774c7fd81b5c2136bde517630582f4678b /system/xar/patches/xar-1.8-arm-ppc.patch
parent7978e324d5b2aad21b6ea5a9862d97e32a7bbcf3 (diff)
system/xar: Added (eXtensible ARchiver)
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'system/xar/patches/xar-1.8-arm-ppc.patch')
-rw-r--r--system/xar/patches/xar-1.8-arm-ppc.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/system/xar/patches/xar-1.8-arm-ppc.patch b/system/xar/patches/xar-1.8-arm-ppc.patch
new file mode 100644
index 000000000000..b2eec5a96e81
--- /dev/null
+++ b/system/xar/patches/xar-1.8-arm-ppc.patch
@@ -0,0 +1,23 @@
+--- a/lib/archive.c
++++ b/lib/archive.c
+@@ -387,7 +387,8 @@
+ return NULL;
+ }
+
+- XAR(ret)->heap_offset = xar_get_heap_offset(ret) + offset;
++ XAR(ret)->heap_offset =
++ XAR(ret)->toc_count + sizeof(xar_header_t) + offset;
+ if( lseek(XAR(ret)->fd, XAR(ret)->heap_offset, SEEK_SET) == -1 ) {
+ xar_close(ret);
+ return NULL;
+--- a/src/xar.c
++++ a/src/xar.c
+@@ -783,7 +783,7 @@
+ int main(int argc, char *argv[]) {
+ int ret;
+ char *filename = NULL;
+- char command = 0, c;
++ signed char command = 0, c;
+ char **args;
+ const char *tocfile = NULL;
+ int arglen, i, err;