summaryrefslogtreecommitdiffstats
path: root/source/groupdb
diff options
context:
space:
mode:
authorMartin Pool <mbp@samba.org>2003-02-18 01:05:56 +0000
committerMartin Pool <mbp@samba.org>2003-02-18 01:05:56 +0000
commitbb095dc28d8369457286225ac63e03070889f394 (patch)
treee938c2b539ef80f67130a49a03dc700f8a935e83 /source/groupdb
parentbcbc2213230e95d732a774b5aee67295fba4380b (diff)
downloadsamba-bb095dc28d8369457286225ac63e03070889f394.tar.gz
samba-bb095dc28d8369457286225ac63e03070889f394.tar.xz
samba-bb095dc28d8369457286225ac63e03070889f394.zip
add_initial_entry should fail if string_to_sid fails.
Diffstat (limited to 'source/groupdb')
-rw-r--r--source/groupdb/mapping.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/groupdb/mapping.c b/source/groupdb/mapping.c
index 3809abc37a9..272783608c5 100644
--- a/source/groupdb/mapping.c
+++ b/source/groupdb/mapping.c
@@ -304,7 +304,11 @@ BOOL add_initial_entry(gid_t gid, const char *sid, enum SID_NAME_USE sid_name_us
}
map.gid=gid;
- string_to_sid(&map.sid, sid);
+ if (!string_to_sid(&map.sid, sid)) {
+ DEBUG(0, ("string_to_sid failed: %s", sid));
+ return False;
+ }
+
map.sid_name_use=sid_name_use;
fstrcpy(map.nt_name, nt_name);
fstrcpy(map.comment, comment);