From: Bo Yang Date: Mon, 7 Apr 2008 13:51:42 +0000 (-0400) Subject: Only cache password policy results that worked, otherwise we X-Git-Tag: samba-3.3.0pre1~2880 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8671f9767d7d93a86712741303d6046937c3aae8;p=thirdparty%2Fsamba.git Only cache password policy results that worked, otherwise we cannot login until the cache expires even if a connection to a DC has been restored. --- diff --git a/source/winbindd/winbindd_cache.c b/source/winbindd/winbindd_cache.c index 0f8bd49d068..e4b0a53d5d1 100644 --- a/source/winbindd/winbindd_cache.c +++ b/source/winbindd/winbindd_cache.c @@ -2232,7 +2232,9 @@ do_query: /* and save it */ refresh_sequence_number(domain, false); - wcache_save_password_policy(domain, status, policy); + if (NT_STATUS_IS_OK(status)) { + wcache_save_password_policy(domain, status, policy); + } return status; }