]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
- Fix gcc 8 buffer warning in testcode.
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 3 May 2018 14:09:33 +0000 (14:09 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 3 May 2018 14:09:33 +0000 (14:09 +0000)
git-svn-id: file:///svn/unbound/trunk@4675 be551aaa-1e26-0410-a405-d3ace91eadb9

doc/Changelog
testcode/testbound.c

index a4034b714c5f41755c2e84ccfd6aaaae97db1ca8..47b3a7c072dd35f97a08ff935be82d54d2c34197 100644 (file)
@@ -1,5 +1,6 @@
 3 May 2018: Wouter
        - Fix that configure --with-libhiredis also turns on cachedb.
+       - Fix gcc 8 buffer warning in testcode.
 
 2 May 2018: Wouter
        - Fix fail to reject dead peers in forward-zone, with ssl-upstream.
index 56b89c7f0d7e17c18bb728449463968d26152cc1..071ac9c2a5b44b389a3239d425e88b0b321ad3bf 100644 (file)
@@ -177,7 +177,8 @@ spool_temp_file(FILE* in, int* lineno, char* id)
                while(isspace((unsigned char)*parse))
                        parse++;
                if(strncmp(parse, "$INCLUDE_TEMPFILE", 17) == 0) {
-                       char l2[MAX_LINE_LEN];
+                       char l2[MAX_LINE_LEN-30]; /* -30 makes it fit with
+                               a preceding $INCLUDE in the buf line[] */
                        char* tid = parse+17;
                        while(isspace((unsigned char)*tid))
                                tid++;