aboutsummaryrefslogtreecommitdiff
path: root/src/namecache/plugin_namecache_flat.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/namecache/plugin_namecache_flat.c')
-rw-r--r--src/namecache/plugin_namecache_flat.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/namecache/plugin_namecache_flat.c b/src/namecache/plugin_namecache_flat.c
index 409b05802d..85bb69237d 100644
--- a/src/namecache/plugin_namecache_flat.c
+++ b/src/namecache/plugin_namecache_flat.c
@@ -132,6 +132,9 @@ database_setup (struct Plugin *plugin)
return GNUNET_SYSERR;
}
+ if (0 == size)
+ return GNUNET_OK;
+
buffer = GNUNET_malloc (size);
if (GNUNET_SYSERR == GNUNET_DISK_file_read (fh,