From 4c90b91082a2fe09fa802c28572b54be07c21fdf Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Thu, 16 Sep 2010 17:09:16 +0200 Subject: Fix sysdb_attrs_to_list --- src/db/sysdb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/db/sysdb.c b/src/db/sysdb.c index 78af9cc53..0091023b6 100644 --- a/src/db/sysdb.c +++ b/src/db/sysdb.c @@ -1991,13 +1991,13 @@ errno_t sysdb_attrs_to_list(TALLOC_CTX *memctx, for (attr_idx = 0; attr_idx < attr_count; attr_idx++) { /* Examine each attribute within the entry */ for (i = 0; i < attrs[attr_idx]->num; i++) { - if (strcasecmp(attrs[attr_idx]->a->name, attr_name) == 0) { + if (strcasecmp(attrs[attr_idx]->a[i].name, attr_name) == 0) { /* Attribute name matches the requested name * Copy it to the output list */ list[list_idx] = talloc_strdup( list, - (const char *)attrs[attr_idx]->a->values[0].data); + (const char *)attrs[attr_idx]->a[i].values[0].data); if (!list[list_idx]) { talloc_free(list); return ENOMEM; -- cgit