summaryrefslogtreecommitdiff
path: root/source3/registry
diff options
context:
space:
mode:
Diffstat (limited to 'source3/registry')
-rw-r--r--source3/registry/reg_cachehook.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/registry/reg_cachehook.c b/source3/registry/reg_cachehook.c
index dc07b51944..1f269276aa 100644
--- a/source3/registry/reg_cachehook.c
+++ b/source3/registry/reg_cachehook.c
@@ -93,7 +93,10 @@ WERROR reghook_cache_add(const char *keyname, struct registry_ops *ops)
DEBUG(10, ("reghook_cache_add: Adding ops %p for key [%s]\n",
(void *)ops, key));
- werr = pathtree_add(cache_tree, key, ops);
+ if (!pathtree_add(cache_tree, key, ops))
+ werr = WERR_NOMEM;
+ else
+ werr = WERR_OK;
done:
TALLOC_FREE(key);