werror: Correct the error code checking
authorGarming Sam <garming@catalyst.net.nz>
Thu, 9 Mar 2017 01:40:11 +0000 (14:40 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 13 Mar 2017 04:10:10 +0000 (05:10 +0100)
Broken in commit ea3c3f10edac2b6e7e1900b4e75f4be4d70d369a

Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
python/samba/netcmd/domain.py

index e03972447259c99c44bb41b8d9e13280cb44d60c..04cd53e7551d8461f277b54ba5dd7203b4194d6c 100644 (file)
@@ -2089,7 +2089,7 @@ class cmd_domain_trust_show(DomainTrustCommand):
                 local_tdo_forest = local_lsa.lsaRQueryForestTrustInformation(local_policy,
                                         lsaString, lsa.LSA_FOREST_TRUST_DOMAIN_INFO)
         except RuntimeError as error:
-            if self.check_runtime_error(error, self.NT_STATUS_RPC_PROCNUM_OUT_OF_RANGE):
+            if self.check_runtime_error(error, ntstatus.NT_STATUS_RPC_PROCNUM_OUT_OF_RANGE):
                 error = None
             if self.check_runtime_error(error, ntstatus.NT_STATUS_NOT_FOUND):
                 error = None