summaryrefslogtreecommitdiff
path: root/server/tools
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2009-07-30 18:03:47 +0200
committerStephen Gallagher <sgallagh@redhat.com>2009-07-31 12:08:39 -0400
commit5e22a141d0d755c1ee54ea40c5795e56ba18d02f (patch)
tree4982cff106e673a65ed8405e1bd414d6a13a2d90 /server/tools
parent6cbe5ee74631122839cb4ebf85be6768e4fd23c5 (diff)
downloadsssd-5e22a141d0d755c1ee54ea40c5795e56ba18d02f.tar.gz
sssd-5e22a141d0d755c1ee54ea40c5795e56ba18d02f.tar.bz2
sssd-5e22a141d0d755c1ee54ea40c5795e56ba18d02f.zip
Use correct return codes
Some code paths that should exit with an error used potentionally incorrect return code.
Diffstat (limited to 'server/tools')
-rw-r--r--server/tools/sss_groupdel.c2
-rw-r--r--server/tools/sss_groupmod.c2
-rw-r--r--server/tools/sss_userdel.c2
-rw-r--r--server/tools/sss_usermod.c2
4 files changed, 4 insertions, 4 deletions
diff --git a/server/tools/sss_groupdel.c b/server/tools/sss_groupdel.c
index 98d73c39..29778263 100644
--- a/server/tools/sss_groupdel.c
+++ b/server/tools/sss_groupdel.c
@@ -99,7 +99,7 @@ static void group_del(struct tevent_req *req)
subreq = sysdb_delete_entry_send(data, data->ev, data->handle, group_dn);
if (!subreq)
- return groupdel_done(data, ret, NULL);
+ return groupdel_done(data, ENOMEM, NULL);
tevent_req_set_callback(subreq, group_del_done, data);
}
diff --git a/server/tools/sss_groupmod.c b/server/tools/sss_groupmod.c
index d91e3771..d6088846 100644
--- a/server/tools/sss_groupmod.c
+++ b/server/tools/sss_groupmod.c
@@ -114,7 +114,7 @@ static void mod_group(struct tevent_req *req)
data->domain, data->name,
attrs, SYSDB_MOD_REP);
if (!subreq) {
- return mod_group_done(data, ret);
+ return mod_group_done(data, ENOMEM);
}
tevent_req_set_callback(subreq, mod_group_attr_done, data);
return;
diff --git a/server/tools/sss_userdel.c b/server/tools/sss_userdel.c
index f70482ce..c4d9abd3 100644
--- a/server/tools/sss_userdel.c
+++ b/server/tools/sss_userdel.c
@@ -100,7 +100,7 @@ static void user_del(struct tevent_req *req)
subreq = sysdb_delete_entry_send(data, data->ev, data->handle, user_dn);
if (!subreq)
- return userdel_done(data, ret, NULL);
+ return userdel_done(data, ENOMEM, NULL);
tevent_req_set_callback(subreq, user_del_done, data);
}
diff --git a/server/tools/sss_usermod.c b/server/tools/sss_usermod.c
index 65e94978..cc94be3a 100644
--- a/server/tools/sss_usermod.c
+++ b/server/tools/sss_usermod.c
@@ -140,7 +140,7 @@ static void mod_user(struct tevent_req *req)
data->domain, data->name,
data->attrs, SYSDB_MOD_REP);
if (!subreq) {
- return mod_user_done(data, ret);
+ return mod_user_done(data, ENOMEM);
}
tevent_req_set_callback(subreq, mod_user_attr_done, data);
return;