summaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorSimo Sorce <ssorce@redhat.com>2009-12-10 14:53:17 -0500
committerStephen Gallagher <sgallagh@redhat.com>2009-12-10 17:20:27 -0500
commitcdfea28842f2ac05808f18240ca0bd48747ea837 (patch)
tree350a2b8d72f34ae60ccce92d831422b4eacdb406 /server
parentfe8224dcf7cf7b0dbe6202057135e3c79529cf68 (diff)
downloadsssd-cdfea28842f2ac05808f18240ca0bd48747ea837.tar.gz
sssd-cdfea28842f2ac05808f18240ca0bd48747ea837.tar.xz
sssd-cdfea28842f2ac05808f18240ca0bd48747ea837.zip
Fix for #316
We were never filling the group attrs because of an inverse return check. Plus fix a crash bug for using a pointer that is not a memory context.
Diffstat (limited to 'server')
-rw-r--r--server/db/sysdb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/server/db/sysdb.c b/server/db/sysdb.c
index a87b5c565..10da9750f 100644
--- a/server/db/sysdb.c
+++ b/server/db/sysdb.c
@@ -271,7 +271,7 @@ int sysdb_attrs_users_from_str_list(struct sysdb_attrs *attrs,
int ret;
ret = sysdb_attrs_get_el(attrs, attr_name, &el);
- if (!ret) {
+ if (ret) {
return ret;
}
@@ -318,11 +318,11 @@ int sysdb_attrs_users_from_ldb_vals(struct sysdb_attrs *attrs,
int ret;
ret = sysdb_attrs_get_el(attrs, attr_name, &el);
- if (!ret) {
+ if (ret) {
return ret;
}
- vals = talloc_realloc(el, el->values, struct ldb_val,
+ vals = talloc_realloc(attrs->a, el->values, struct ldb_val,
el->num_values + num_values);
if (!vals) {
return ENOMEM;