Package: getdns / 1.6.0-3.2

0006-Fix-incorrect-assertion.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Description: Fix incorrectly-written assertion breaking builds with gcc-14.
 An assertion in test code was written incorrectly in a way that would always
 succeed. This patch was independently developed to fix the Debian build but
 the bug is also fixed as part of a larger patch fixing compiler warnings
 upstream and is present in v1.7.0~rc.1 onwards. Importing the latest
 upstream release will obviate the need for this patch.
Author: Andrew Bower <andrew@bower.uk>
Bug-Debian: https://bugs.debian.org/1074989
Forwarded: not-needed
Applied-Upstream: https://github.com/getdnsapi/getdns/commit/df2997d9b762d705d5f7add338e460686c9bd88f
Last-Update: 2024-12-10

--- getdns-1.6.0.orig/src/test/check_getdns_dict_set_bindata.h
+++ getdns-1.6.0/src/test/check_getdns_dict_set_bindata.h
@@ -112,7 +112,7 @@
       ASSERT_RC(getdns_dict_get_bindata(this_dict, "bindata", &retrieved_bindata),
         GETDNS_RETURN_GOOD, "Return code from getdns_dict_get_bindata()");
 
-      ck_assert_msg(retrieved_bindata->size, second_bindata.size,
+      ck_assert_msg(retrieved_bindata->size == second_bindata.size,
         "Expected retrieved bindata size == %d, got: %d",
         second_bindata.size, retrieved_bindata->size);