]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[2275] valgrind fixes: uninitialized memory
authorJelte Jansen <jelte@isc.org>
Thu, 4 Oct 2012 13:57:43 +0000 (15:57 +0200)
committerJelte Jansen <jelte@isc.org>
Thu, 4 Oct 2012 14:12:27 +0000 (16:12 +0200)
src/lib/util/tests/fd_tests.cc

index 6ba27663c445ee91017336b49c2568b78cb16d55..b709405116b56294ff0cb0ba41e764c205075db1 100644 (file)
@@ -34,7 +34,9 @@ class FDTest : public ::testing::Test {
             // We do not care what is inside, we just need it to be the same
             data(new unsigned char[TEST_DATA_SIZE]),
             buffer(NULL)
-        { }
+        {
+            memset(data, 0, TEST_DATA_SIZE);
+        }
         ~ FDTest() {
             delete[] data;
             delete[] buffer;