diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2003-09-06 12:21:08 +0000 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2003-09-06 12:21:08 +0000 |
commit | 14b438e90ac44acb2b66354a5ad16779ae0c88b2 (patch) | |
tree | 281ce6630eceff5a3fe191a966d42203bb0e2c2e /source3 | |
parent | aa8b2d08093ebcf62a84f6f47b4b66be177cd2b7 (diff) | |
download | samba-14b438e90ac44acb2b66354a5ad16779ae0c88b2.tar.gz samba-14b438e90ac44acb2b66354a5ad16779ae0c88b2.tar.bz2 samba-14b438e90ac44acb2b66354a5ad16779ae0c88b2.zip |
Only set sids when they're retrurned by the MySQL query
(This used to be commit 9a603f6f077a2e1ddc41849cca3641421ecbaf11)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/passdb/pdb_mysql.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/passdb/pdb_mysql.c b/source3/passdb/pdb_mysql.c index d3eb7cb975..6c200be504 100644 --- a/source3/passdb/pdb_mysql.c +++ b/source3/passdb/pdb_mysql.c @@ -240,9 +240,9 @@ static NTSTATUS row_to_sam_account(MYSQL_RES * r, SAM_ACCOUNT * u) pdb_set_unknown_str(u, row[16], PDB_SET); pdb_set_munged_dial(u, row[17], PDB_SET); - string_to_sid(&sid, row[18]); + if(row[18])string_to_sid(&sid, row[18]); pdb_set_user_sid(u, &sid, PDB_SET); - string_to_sid(&sid, row[19]); + if(row[19])string_to_sid(&sid, row[19]); pdb_set_group_sid(u, &sid, PDB_SET); if (pdb_gethexpwd(row[20], temp), PDB_SET) |