Apply Jim Meyering's fix from 2015-01-11 to more tests.
authorBruno Haible <bruno@clisp.org>
Wed, 12 Sep 2018 19:27:52 +0000 (21:27 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 12 Sep 2018 19:27:52 +0000 (21:27 +0200)
* tests/test-memmem.c (main): Free haystack.
* tests/test-strcasestr.c (main): Likewise.
* tests/test-c-strcasestr.c (main): Likewise.

ChangeLog
tests/test-c-strcasestr.c
tests/test-memmem.c
tests/test-strcasestr.c

index 2243876d4a602a1a1cd66f38db07679b8959c0c8..51a28217f3696a5c12bb41ccb446f8e4cb02724f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2018-09-12  Bruno Haible  <bruno@clisp.org>
+
+       Apply Jim Meyering's fix from 2015-01-11 to more tests.
+       * tests/test-memmem.c (main): Free haystack.
+       * tests/test-strcasestr.c (main): Likewise.
+       * tests/test-c-strcasestr.c (main): Likewise.
+
 2018-09-11  Paul Eggert  <eggert@cs.ucla.edu>
 
        xstrtol: fix missing-TYPE_SIGNED typo
index f25ccc0561332bd3ad7a9bb9d2032538456cd944..ac1c44d41fb18540091bd96003c500aa9c6bc824 100644 (file)
@@ -235,6 +235,7 @@ main ()
         ASSERT (p);
         ASSERT (p - haystack == i);
       }
+    free (haystack);
   }
 
   return 0;
index 5c56183931ab46c22d867446772d639497b762e7..622932d25c1ee0075f69cf560653b98cf96a0f59 100644 (file)
@@ -286,6 +286,7 @@ main (int argc, char *argv[])
         ASSERT (p);
         ASSERT (p - haystack == i);
       }
+    free (haystack);
   }
 
   return 0;
index 5d2bfee855b8db93cb49bc58900086adcbdb3478..21192bc2a88c97e3cc4fae79ca9b8a276e312e83 100644 (file)
@@ -249,6 +249,7 @@ main ()
         ASSERT (p);
         ASSERT (p - haystack == i);
       }
+    free (haystack);
   }
 
   return 0;