From 4864cd9ec24e9c45c64b7e3624eb3c65ac8f171f Mon Sep 17 00:00:00 2001 From: "Nathan S. Evans" Date: Fri, 2 Jul 2010 16:01:09 +0000 Subject: [PATCH] failing datacache testcase --- src/datacache/test_datacache.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/datacache/test_datacache.c b/src/datacache/test_datacache.c index d323d955a..1b2aee42f 100644 --- a/src/datacache/test_datacache.c +++ b/src/datacache/test_datacache.c @@ -97,6 +97,19 @@ run (void *cls, &checkIt, &n)); k = n; } + + memset(&k, 42, sizeof(GNUNET_HashCode)); + GNUNET_CRYPTO_hash (&k, sizeof (GNUNET_HashCode), &n); + ASSERT (GNUNET_OK == GNUNET_DATACACHE_put (h, + &k, + sizeof (GNUNET_HashCode), + (const char *) &n, + 792, + GNUNET_TIME_absolute_get_forever())); + ASSERT (1 == + GNUNET_DATACACHE_get (h, &k, 792, + &checkIt, &n)); + GNUNET_DATACACHE_destroy (h); ASSERT (ok == 0); return; -- 2.25.1