diff options
author | Günther Deschner <gd@samba.org> | 2006-10-25 12:10:48 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:15:39 -0500 |
commit | 78f977f746cf1f83fe1cc6f09634a831171a3435 (patch) | |
tree | 03ba3a8fff86b4543ec4e52bafbe48c92c7a60fe | |
parent | 151237477bef0d8fdcf926fa0fbe048580a58be5 (diff) | |
download | samba-78f977f746cf1f83fe1cc6f09634a831171a3435.tar.gz samba-78f977f746cf1f83fe1cc6f09634a831171a3435.tar.bz2 samba-78f977f746cf1f83fe1cc6f09634a831171a3435.zip |
r19493: There is no point in prompting for a user's password in "net ads" when
we can't find a domain controller at all.
Guenther
(This used to be commit e691ae7da3620a7d4c0e0b1217aaae44db0b8db3)
-rw-r--r-- | source3/utils/net_ads.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/utils/net_ads.c b/source3/utils/net_ads.c index 7902248f94..97b64a271c 100644 --- a/source3/utils/net_ads.c +++ b/source3/utils/net_ads.c @@ -282,6 +282,14 @@ retry: status = ads_connect(ads); if (!ADS_ERR_OK(status)) { + + if (NT_STATUS_EQUAL(ads_ntstatus(status), + NT_STATUS_NO_LOGON_SERVERS)) { + DEBUG(0,("ads_connect: %s\n", ads_errstr(status))); + ads_destroy(&ads); + return status; + } + if (!need_password && !second_time) { need_password = True; second_time = True; |