From c259a90fa40204f0f434f8481b4c5a16f78acfba Mon Sep 17 00:00:00 2001 From: Quinn Date: Tue, 20 Jan 2026 11:24:03 +0100 Subject: [PATCH] Rename `CONF_I*` to `CONF_S`, to match the recent typedef change. Note: not changing `NBT_I*` macros, since the NBT specification does not specify a difference between signed/unsigned types. Generally speaking, internally we treat these as unsigned types for the purpose of computations being correct. --- src/io/conf.c | 8 ++++---- src/io/conf.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/io/conf.c b/src/io/conf.c index d67c416..f1d11e6 100644 --- a/src/io/conf.c +++ b/src/io/conf.c @@ -48,10 +48,10 @@ int conf_procval(u8 type, const char *val, void *out) switch (type) { case CONF_STR: *(char **)out = strdup(val); return 0; - case CONF_I8: *(s8 *)out = strtoimax(val, &end, 0); return (end && !*end); - case CONF_I16: *(s16 *)out = strtoimax(val, &end, 0); return (end && !*end); - case CONF_I32: *(s32 *)out = strtoimax(val, &end, 0); return (end && !*end); - case CONF_I64: *(s64 *)out = strtoimax(val, &end, 0); return (end && !*end); + case CONF_S8: *(s8 *)out = strtoimax(val, &end, 0); return (end && !*end); + case CONF_S16: *(s16 *)out = strtoimax(val, &end, 0); return (end && !*end); + case CONF_S32: *(s32 *)out = strtoimax(val, &end, 0); return (end && !*end); + case CONF_S64: *(s64 *)out = strtoimax(val, &end, 0); return (end && !*end); case CONF_U8: *(u8 *)out = strtoumax(val, &end, 0); return (end && !*end); case CONF_U16: *(u16 *)out = strtoumax(val, &end, 0); return (end && !*end); diff --git a/src/io/conf.h b/src/io/conf.h index 2de909f..c11e539 100644 --- a/src/io/conf.h +++ b/src/io/conf.h @@ -9,10 +9,10 @@ enum conf_type { CONF_STR = 0x00, - CONF_I8 = 0x00 | 0x01, - CONF_I16 = 0x00 | 0x02, - CONF_I32 = 0x00 | 0x04, - CONF_I64 = 0x00 | 0x08, + CONF_S8 = 0x00 | 0x01, + CONF_S16 = 0x00 | 0x02, + CONF_S32 = 0x00 | 0x04, + CONF_S64 = 0x00 | 0x08, CONF_U8 = 0x10 | 0x01, CONF_U16 = 0x10 | 0x02, CONF_U32 = 0x10 | 0x04,