From 5802608956719139efdb43e9407f8bdac2e46543 Mon Sep 17 00:00:00 2001 From: William Storey Date: Sun, 13 Sep 2026 16:54:18 +0000 Subject: [PATCH 1/2] Add changelog entry for the 32-bit sign-compare fix The fix in #487 resolved a build failure for packagers on platforms where ssize_t is 32 bits, such as i686, where -Werror turns the -Wsign-compare warning into an error. Co-Authored-By: Claude Opus 5 (1M context) --- Changes.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Changes.md b/Changes.md index 44956a7c..4bb1ef96 100644 --- a/Changes.md +++ b/Changes.md @@ -1,3 +1,9 @@ +## next release + +- Fixed a `-Wsign-compare` warning in `MMDB_open()` that broke builds with + `-Werror` on platforms where `ssize_t` is 32 bits, such as i686. Pull request + by Robert Scheck. GitHub #487. + ## 1.14.0 - 2026-09-08 - Bounded the resources that `MMDB_get_entry_data_list()` spends decoding a From 69698455133041998d1facaa0f263884fc62379d Mon Sep 17 00:00:00 2001 From: William Storey Date: Sun, 13 Sep 2026 16:54:58 +0000 Subject: [PATCH 2/2] Fix duplicated word in data section size comment Co-Authored-By: Claude Opus 5 (1M context) --- src/maxminddb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/maxminddb.c b/src/maxminddb.c index d9cc9c56..95ca7a7d 100644 --- a/src/maxminddb.c +++ b/src/maxminddb.c @@ -374,9 +374,9 @@ int MMDB_open(const char *const filename, uint32_t flags, MMDB_s *const mmdb) { mmdb->data_section_size = (uint32_t)data_section_size; // Although it is likely not possible to construct a database with valid - // valid metadata, as parsed above, and a data_section_size less than 3, - // we do this check as later we assume it is at least three when doing - // bound checks. + // metadata, as parsed above, and a data_section_size less than 3, we do + // this check as later we assume it is at least three when doing bound + // checks. if (mmdb->data_section_size < 3) { status = MMDB_INVALID_DATA_ERROR; goto cleanup;