From 5aefb44bf04becc6b80e7c3bf038d79851c5b0f9 Mon Sep 17 00:00:00 2001 From: Aravind Srinivasan Date: Thu, 16 Apr 2009 20:42:40 +0000 Subject: s3: Fallback to the legacy sid_to_(uid|gid) instead of returning NULL. This is very similar to be1dfff02d562e42a7847bd02fed8538630d3f41 --- source3/passdb/lookup_sid.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'source3/passdb/lookup_sid.c') diff --git a/source3/passdb/lookup_sid.c b/source3/passdb/lookup_sid.c index c1249f5eb4..b45000e77e 100644 --- a/source3/passdb/lookup_sid.c +++ b/source3/passdb/lookup_sid.c @@ -1430,13 +1430,10 @@ bool sid_to_uid(const DOM_SID *psid, uid_t *puid) if (!ret || expired) { /* Not in cache. Ask winbindd. */ if (!winbind_sid_to_uid(puid, psid)) { - if (!winbind_ping()) { - return legacy_sid_to_uid(psid, puid); - } - DEBUG(5, ("winbind failed to find a uid for sid %s\n", sid_string_dbg(psid))); - return false; + /* winbind failed. do legacy */ + return legacy_sid_to_uid(psid, puid); } } @@ -1497,13 +1494,11 @@ bool sid_to_gid(const DOM_SID *psid, gid_t *pgid) * (Idmap will check it is a valid SID and of the right type) */ if ( !winbind_sid_to_gid(pgid, psid) ) { - if (!winbind_ping()) { - return legacy_sid_to_gid(psid, pgid); - } DEBUG(10,("winbind failed to find a gid for sid %s\n", sid_string_dbg(psid))); - return false; + /* winbind failed. do legacy */ + return legacy_sid_to_gid(psid, pgid); } } -- cgit