summaryrefslogtreecommitdiffstats
path: root/source3/lib/gencache.c
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-06-16 12:30:39 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:17:31 -0500
commit366a2d498d115503067f306a1891ec2063baaeb8 (patch)
tree763a6a94bf1e178a5e34145b9e7305866d083d45 /source3/lib/gencache.c
parente0055ce8f5b496e7c3490577a68cf4a49e456456 (diff)
downloadsamba-366a2d498d115503067f306a1891ec2063baaeb8.tar.gz
samba-366a2d498d115503067f306a1891ec2063baaeb8.tar.xz
samba-366a2d498d115503067f306a1891ec2063baaeb8.zip
r16290: Fix Coverity bugs 298 and 298
(This used to be commit b96808bb623c01f2515fdbdede8b4e9edebff23b)
Diffstat (limited to 'source3/lib/gencache.c')
-rw-r--r--source3/lib/gencache.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/lib/gencache.c b/source3/lib/gencache.c
index defc7ca2065..561a019429a 100644
--- a/source3/lib/gencache.c
+++ b/source3/lib/gencache.c
@@ -349,7 +349,7 @@ void gencache_iterate(void (*fn)(const char* key, const char *value, time_t time
/* ensure null termination of the key string */
keystr = SMB_STRNDUP(node->node_key.dptr, node->node_key.dsize);
if (!keystr) {
- return;
+ break;
}
/*
@@ -367,7 +367,7 @@ void gencache_iterate(void (*fn)(const char* key, const char *value, time_t time
if (!entry) {
SAFE_FREE(databuf.dptr);
SAFE_FREE(keystr);
- return;
+ break;
}
SAFE_FREE(databuf.dptr);
@@ -376,7 +376,7 @@ void gencache_iterate(void (*fn)(const char* key, const char *value, time_t time
if (!valstr) {
SAFE_FREE(entry);
SAFE_FREE(keystr);
- return;
+ break;
}
asprintf(&fmt, READ_CACHE_DATA_FMT_TEMPLATE, (unsigned int)databuf.dsize - TIMEOUT_LEN);
@@ -384,7 +384,7 @@ void gencache_iterate(void (*fn)(const char* key, const char *value, time_t time
SAFE_FREE(valstr);
SAFE_FREE(entry);
SAFE_FREE(keystr);
- return;
+ break;
}
status = sscanf(entry, fmt, &u, valstr);
SAFE_FREE(fmt);