From 27cd6a2b882ae7d77478bbd14ed8fa150d491de6 Mon Sep 17 00:00:00 2001 From: Josh Megnauth Date: Tue, 18 Feb 2025 00:06:58 -0500 Subject: [PATCH] fix: USHRT_MAX is too large The original expanded to 16 nibbles which is technically correct because the standard defines USHRT_MAX as being at LEAST 65535. However, in practice everything seems to set the max as the max length of two bytes. --- include/bits/limits.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/bits/limits.h b/include/bits/limits.h index ec4b39a9b0..befcbec766 100644 --- a/include/bits/limits.h +++ b/include/bits/limits.h @@ -26,7 +26,7 @@ #define UINT_MAX 0xffffffff #define ULLONG_MAX 0xffffffffffffffff #define ULONG_MAX 0xffffffffffffffff -#define USHRT_MAX 0xffffffffffffffff +#define USHRT_MAX 0xffff #define WORD_BIT 32 #endif