Revert "s4/ldapcmp: Check if creds2 is actualy set by the command line"
authorAnatoliy Atanasov <anatoliy.atanasov@postpath.com>
Wed, 5 Jan 2011 13:32:06 +0000 (15:32 +0200)
committerAnatoliy Atanasov <anatoliy.atanasov@postpath.com>
Wed, 5 Jan 2011 14:14:14 +0000 (16:14 +0200)
This reverts commit f8275bae5d7b471967be7222170d049c18b8882f.
Wrong assumption about a segmentation fault.

source4/scripting/python/samba/netcmd/ldapcmp.py

index 76f7d957564491bcf00f74840b9c133b2f220ed9..1ecbda73a9ba46a57761b2205fd8526f241604d7 100755 (executable)
@@ -772,7 +772,7 @@ class cmd_ldapcmp(Command):
         lp = sambaopts.get_loadparm()
         creds = credopts.get_credentials(lp, fallback_machine=True)
         creds2 = credopts.get_credentials2(lp)
-        if credopts.no_pass2:
+        if creds2.is_anonymous():
             creds2 = creds
         if not creds.authentication_requested():
             raise CommandError("You must supply at least one username/password pair")