From cca771e70e862053b54bf7a724c4b4926341e2c1 Mon Sep 17 00:00:00 2001 From: cpq Date: Sat, 1 Jul 2023 20:23:59 +0100 Subject: [PATCH] Stricter check for test_dns_error() --- test/unit_test.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/unit_test.c b/test/unit_test.c index 2b432b14..1382af85 100644 --- a/test/unit_test.c +++ b/test/unit_test.c @@ -1920,8 +1920,10 @@ static void test_str(void) { } static void fn1(struct mg_connection *c, int ev, void *ev_data, void *fn_data) { - if (ev == MG_EV_ERROR) + if (ev == MG_EV_ERROR) { + ASSERT(* (void **) fn_data == NULL); *(char **) fn_data = mg_mprintf("%s", (char *) ev_data); + } (void) c; }