svn commit: samba r18875 - in branches/SAMBA_3_0/source/groupdb: .
vlendec at samba.org
vlendec at samba.org
Sun Sep 24 22:10:50 GMT 2006
Author: vlendec
Date: 2006-09-24 22:10:48 +0000 (Sun, 24 Sep 2006)
New Revision: 18875
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18875
Log:
The comment field can be empty
Modified:
branches/SAMBA_3_0/source/groupdb/mapping_ldb.c
Changeset:
Modified: branches/SAMBA_3_0/source/groupdb/mapping_ldb.c
===================================================================
--- branches/SAMBA_3_0/source/groupdb/mapping_ldb.c 2006-09-24 22:10:20 UTC (rev 18874)
+++ branches/SAMBA_3_0/source/groupdb/mapping_ldb.c 2006-09-24 22:10:48 UTC (rev 18875)
@@ -149,11 +149,15 @@
sid_to_string(string_sid, &map->sid)) != LDB_SUCCESS ||
ldb_msg_add_fmt(msg, "gidNumber", "%u", (unsigned)map->gid) != LDB_SUCCESS ||
ldb_msg_add_fmt(msg, "sidNameUse", "%u", (unsigned)map->sid_name_use) != LDB_SUCCESS ||
- ldb_msg_add_string(msg, "ntName", map->nt_name) != LDB_SUCCESS ||
- ldb_msg_add_string(msg, "comment", map->comment) != LDB_SUCCESS) {
+ ldb_msg_add_string(msg, "ntName", map->nt_name) != LDB_SUCCESS) {
goto failed;
}
+ if ((map->comment[0] != '\0') &&
+ (ldb_msg_add_string(msg, "ntName", map->nt_name) != LDB_SUCCESS)) {
+ goto failed;
+ }
+
ret = ldb_add(ldb, msg);
/* if it exists we update it. This is a hangover from the semantics the
More information about the samba-cvs
mailing list