]> git.ozlabs.org Git - ccan/blobdiff - ccan/tdb2/test/run-12-store.c
tdb2: move open routines into a separate file (open.c)
[ccan] / ccan / tdb2 / test / run-12-store.c
index 2cc3e86b6a50bb2c650ffdf5aff453c6ca8f4c31..0b3c29651c44b2cebcc9b4c4fb09754f15afa423 100644 (file)
@@ -1,4 +1,5 @@
 #include <ccan/tdb2/tdb.c>
+#include <ccan/tdb2/open.c>
 #include <ccan/tdb2/free.c>
 #include <ccan/tdb2/lock.c>
 #include <ccan/tdb2/io.c>
@@ -50,7 +51,7 @@ int main(int argc, char *argv[])
                /* We seemed to lose some keys.
                 * Insert and check they're in there! */
                for (j = 0; j < 500; j++) {
-                       struct tdb_data d;
+                       struct tdb_data d = { NULL, 0 }; /* Bogus GCC warning */
                        ok1(tdb_store(tdb, key, data, TDB_REPLACE) == 0);
                        ok1(tdb_fetch(tdb, key, &d) == TDB_SUCCESS);
                        ok1(equal(d, data));