summaryrefslogtreecommitdiffstats
path: root/src/tools
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2010-06-03 18:44:26 +0200
committerStephen Gallagher <sgallagh@redhat.com>2010-06-09 08:29:47 -0400
commitcf16f9d120c8e2802927dd72d4de74b8ba42ff0a (patch)
tree804cb894b5fdc925fc35aba2829da0dda5c98324 /src/tools
parentbe3cb9b976bd994b2cd6e0217e41892f46d174dd (diff)
downloadsssd_unused-cf16f9d120c8e2802927dd72d4de74b8ba42ff0a.tar.gz
sssd_unused-cf16f9d120c8e2802927dd72d4de74b8ba42ff0a.tar.xz
sssd_unused-cf16f9d120c8e2802927dd72d4de74b8ba42ff0a.zip
Fix potential NULL dereference in sss_groupshow
Fixes: #510
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/sss_groupshow.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/tools/sss_groupshow.c b/src/tools/sss_groupshow.c
index 084da21b..21337203 100644
--- a/src/tools/sss_groupshow.c
+++ b/src/tools/sss_groupshow.c
@@ -595,11 +595,13 @@ static void group_show_trim_memberof_done(struct tevent_req *subreq)
const char *, state->ndirect+2);
if (!state->direct) {
tevent_req_error(req, ENOMEM);
+ return;
}
state->direct[state->ndirect] = talloc_strdup(state->direct, name);
if (!state->direct[state->ndirect]) {
tevent_req_error(req, ENOMEM);
+ return;
}
state->direct[state->ndirect+1] = NULL;