From 7ff9823689638b1a7f82c277a6c825f4ac883d96 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Wed, 13 Jan 1999 00:40:04 +0000 Subject: fixed an uninitialized variable in lookupsmbgrpgid() and lookupsmbpwuid that was causing a SEGFAULT in smbd. (This used to be commit cabc7e739cb6a6c8dfc4b6988a8ef5837e3312d2) --- source3/lib/domain_namemap.c | 2 ++ source3/lib/util_pwdb.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/source3/lib/domain_namemap.c b/source3/lib/domain_namemap.c index cb0e315ef5..f095c8d764 100644 --- a/source3/lib/domain_namemap.c +++ b/source3/lib/domain_namemap.c @@ -1026,6 +1026,7 @@ BOOL lookupsmbpwuid(uid_t uid, DOM_NAME_MAP *gmep) { gmep->nt_name = nt_name; gmep->unix_name = unix_name; + gmep->nt_domain = nt_domain; gmep->unix_id = (uint32)uid; @@ -1279,6 +1280,7 @@ BOOL lookupsmbgrpgid(gid_t gid, DOM_NAME_MAP *gmep) { gmep->nt_name = nt_name; gmep->unix_name = unix_name; + gmep->nt_domain = nt_domain; gmep->unix_id = (uint32)gid; diff --git a/source3/lib/util_pwdb.c b/source3/lib/util_pwdb.c index a2e1ac010d..6a37f1bf74 100644 --- a/source3/lib/util_pwdb.c +++ b/source3/lib/util_pwdb.c @@ -318,7 +318,7 @@ static time_t get_time_from_string(const char *p) time_t pwdb_get_last_set_time(const char *p) { - if (*p && StrnCaseCmp(p, "LCT-", 4)) + if (*p && !StrnCaseCmp(p, "LCT-", 4)) { return get_time_from_string(p + 4); } -- cgit