s4:samba_spnupdate: do not attempt to parse log level, use parsed value
authorChristian Ambach <ambi@samba.org>
Tue, 13 Sep 2016 08:49:47 +0000 (10:49 +0200)
committerChristian Ambach <ambi@samba.org>
Wed, 14 Sep 2016 21:15:18 +0000 (23:15 +0200)
The log level parameter can contain debug class specific entries.
Do not attempt to parse this as int, but use the values that the
debugging system already parsed

BUG: https://bugzilla.samba.org/show_bug.cgi?id=9945
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Christian Ambach <ambi@samba.org>
Autobuild-Date(master): Wed Sep 14 23:15:18 CEST 2016 on sn-devel-144

source4/scripting/bin/samba_spnupdate

index 977de68bc2c35930ec86a01897e88fbe3e7f47de..c83e5753eeada0fb58a75f731c5e58d0be9f47b3 100755 (executable)
@@ -219,7 +219,7 @@ def call_rodc_update(d):
     server = cldap_ret.pdc_dns_name
     try:
         binding_options = "seal"
-        if int(lp.get("log level")) >= 5:
+        if lp.log_level() >= 5:
             binding_options += ",print"
         drs = drsuapi.drsuapi('ncacn_ip_tcp:%s[%s]' % (server, binding_options), lp, creds)
         (drs_handle, supported_extensions) = drs_utils.drs_DsBind(drs)