diff options
-rw-r--r-- | pack.c | 8 |
1 files changed, 1 insertions, 7 deletions
@@ -59,13 +59,7 @@ enum pack_status pack(void *buf_, size_t size, const char *fmt, ...) if (sign) { intmax_t n = v.signed_; tr_debug("val.s: %" PRIdMAX, v.signed_); - if (v.signed_ >= 0) { - v.unsigned_ = n; - } else { - uintmax_t offt = BITMASK(s * 8); - n += 1; - v.unsigned_ = offt + n; - } + v.unsigned_ = n; } tr_debug("val.u: %" PRIuMAX, v.unsigned_); write_val(&buf[offset], s, endianness, v.unsigned_); |