diff options
author | Leah Neukirchen <leah@vuxu.org> | 2023-10-13 17:27:31 +0200 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2023-10-13 17:27:31 +0200 |
commit | c4d638581aa4a9cfa4b622ce8547b6fc98896bd1 (patch) | |
tree | 772f60f3a10f63a59854c2099013325dd78ea092 /mico-dump.c | |
parent | 7f7cfbbead307c4d522af19bfdcfdd58edc98458 (diff) | |
download | mico-c4d638581aa4a9cfa4b622ce8547b6fc98896bd1.tar.gz mico-c4d638581aa4a9cfa4b622ce8547b6fc98896bd1.tar.xz mico-c4d638581aa4a9cfa4b622ce8547b6fc98896bd1.zip |
store 64-bit signed int after 1111
Diffstat (limited to 'mico-dump.c')
-rw-r--r-- | mico-dump.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/mico-dump.c b/mico-dump.c index 982c1b4..ce13a3e 100644 --- a/mico-dump.c +++ b/mico-dump.c @@ -61,7 +61,7 @@ getsigned(struct bitreader *input, int count) return bits; } -static int32_t +static int64_t get1(struct bitreader *input) { if (getbits1_msb(input, 1) == 0) @@ -72,7 +72,12 @@ get1(struct bitreader *input) return getsigned(input, 9); if (getbits1_msb(input, 1) == 0) return getsigned(input, 12); - return getsigned(input, 32); + + int64_t v = getsigned(input, 32); + v <<= 32; + v |= getbits1_msb(input, 32); + + return v; } int |