[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Freeipa-devel] [PATHC] provide sysdb_set_user_attr



Simo Sorce schrieb:
> See patch.
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Freeipa-devel mailing list
> Freeipa-devel redhat com
> https://www.redhat.com/mailman/listinfo/freeipa-devel

ack, with the applied patch :)

works great, thanks
>From 2b37ab876b74d98d10b402069adbe72940b60028 Mon Sep 17 00:00:00 2001
From: Sumit Bose <sbose redhat com>
Date: Tue, 3 Mar 2009 10:14:24 +0100
Subject: [PATCH] copy number of attributes, too

---
 server/db/sysdb_ops.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/server/db/sysdb_ops.c b/server/db/sysdb_ops.c
index e9ba46a..afe2506 100644
--- a/server/db/sysdb_ops.c
+++ b/server/db/sysdb_ops.c
@@ -471,6 +471,8 @@ int sysdb_set_user_attr(struct sysdb_req *sysreq,
     msg->elements = talloc_array(msg, struct ldb_message_element, attrs->num);
     if (!msg->elements) return ENOMEM;
 
+    msg->num_elements = attrs->num;
+
     for (i = 0; i < attrs->num; i++) {
         msg->elements[i] = attrs->a[i];
         msg->elements[i].flags = LDB_FLAG_MOD_REPLACE;
-- 
1.6.0.6


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]