From: Robert Pengelly Date: Thu, 12 Jun 2025 20:31:09 +0000 (+0100) Subject: Don't foget to change to big endian numbers X-Git-Url: https://git.candlhat.org/?a=commitdiff_plain;h=844dd879f1cbce51c34f6d933b35a821f70e87a9;p=xar.git Don't foget to change to big endian numbers --- diff --git a/ranlib.c b/ranlib.c index 728a962..2e13537 100644 --- a/ranlib.c +++ b/ranlib.c @@ -408,7 +408,7 @@ static void hunk_get_symbols (void *object, unsigned long bytes, long offset) { while (1) { - name_size = array_to_integer (pos, 4); + name_size = array_to_be_integer (pos, 4); pos += 4; if (name_size == 0) { @@ -439,7 +439,7 @@ static void hunk_get_symbols (void *object, unsigned long bytes, long offset) { pos += 4; } - num_ref = array_to_integer (pos, 4); + num_ref = array_to_be_integer (pos, 4); num_ref *= 4; pos = pos + 4 + num_ref; @@ -505,7 +505,7 @@ static void omf_get_symbols (void *object, char *filename, unsigned long bytes, big_fields = record_type & 1; record_type &= ~1; - record_len = array_to_integer (pos + 1, 2); + record_len = array_to_be_integer (pos + 1, 2); {