summaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2012-06-13 15:08:05 +0200
committerStephen Gallagher <sgallagh@redhat.com>2012-06-13 10:01:12 -0400
commit94a104f808e76c19b33a3a63f3b637b1475d8c17 (patch)
tree9ee01d2a8e0db757640853406f1da7b132372122 /src/util
parent19d69c58b288e10212ff83ae77b913fd0e2badd0 (diff)
downloadsssd-94a104f808e76c19b33a3a63f3b637b1475d8c17.tar.gz
sssd-94a104f808e76c19b33a3a63f3b637b1475d8c17.tar.bz2
sssd-94a104f808e76c19b33a3a63f3b637b1475d8c17.zip
sss_names_init: Report correct error code if allocation failed
Diffstat (limited to 'src/util')
-rw-r--r--src/util/usertools.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/util/usertools.c b/src/util/usertools.c
index 7675585e..a3d210e3 100644
--- a/src/util/usertools.c
+++ b/src/util/usertools.c
@@ -70,7 +70,10 @@ int sss_names_init(TALLOC_CTX *mem_ctx, struct confdb_ctx *cdb,
talloc_set_destructor(ctx, sss_names_ctx_destructor);
tmpctx = talloc_new(NULL);
- if (tmpctx == NULL) goto done;
+ if (tmpctx == NULL) {
+ ret = ENOMEM;
+ goto done;
+ }
conf_path = talloc_asprintf(tmpctx, CONFDB_DOMAIN_PATH_TMPL, domain);
if (conf_path == NULL) {