Skip to content

Commit

Permalink
Merge pull request #369 from maxmind/greg/eng-1020-libmaxminddb-1122-…
Browse files Browse the repository at this point in the history
…is-released

Release 1.12.2
  • Loading branch information
horgh authored Jan 10, 2025
2 parents 8d84eda + cba618d commit b2e9c37
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 13 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required (VERSION 3.9...3.30)

project(maxminddb
LANGUAGES C
VERSION 1.12.1
VERSION 1.12.2
)
set(MAXMINDDB_SOVERSION 0.0.7)
set(CMAKE_C_STANDARD 99)
Expand Down
2 changes: 1 addition & 1 deletion Changes.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## 1.12.2
## 1.12.2 - 2025-01-10

* `MMDB_get_entry_data_list()` now always sets the passed `entry_data_list`
parameter to either `NULL` or valid memory. This makes it safe for
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.

AC_PREREQ([2.63])
AC_INIT([libmaxminddb], [1.12.1], [[email protected]])
AC_INIT([libmaxminddb], [1.12.2], [[email protected]])
AC_CONFIG_SRCDIR([include/maxminddb.h])
AC_CONFIG_HEADERS([config.h include/maxminddb_config.h])

Expand Down
8 changes: 6 additions & 2 deletions src/data-pool.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,13 @@ int main(void) {
}

static void test_can_multiply(void) {
{ ok(can_multiply(SIZE_MAX, 1, SIZE_MAX), "1*SIZE_MAX is ok"); }
{
ok(can_multiply(SIZE_MAX, 1, SIZE_MAX), "1*SIZE_MAX is ok");
}

{ ok(!can_multiply(SIZE_MAX, 2, SIZE_MAX), "2*SIZE_MAX is not ok"); }
{
ok(!can_multiply(SIZE_MAX, 2, SIZE_MAX), "2*SIZE_MAX is not ok");
}

{
ok(can_multiply(SIZE_MAX, 10240, sizeof(MMDB_entry_data_list_s)),
Expand Down
4 changes: 3 additions & 1 deletion t/data-pool-t.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ static void test_data_pool_new(void) {
}

static void test_data_pool_destroy(void) {
{ data_pool_destroy(NULL); }
{
data_pool_destroy(NULL);
}

{
MMDB_data_pool_s *const pool = data_pool_new(512);
Expand Down
12 changes: 5 additions & 7 deletions t/fuzz_mmdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@

extern int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size);

int
LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
{
int status;
FILE *fp;
MMDB_s mmdb;
char filename[256];
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
int status;
FILE *fp;
MMDB_s mmdb;
char filename[256];

if (size < kMinInputLength || size > kMaxInputLength)
return 0;
Expand Down

0 comments on commit b2e9c37

Please sign in to comment.