From: Noel Power Date: Fri, 12 Oct 2018 16:15:39 +0000 (+0100) Subject: python/samba: PY3 fix can't compare string with int X-Git-Tag: tdb-1.3.17~767 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f176461cf29908f3555eecc2463d00e2ffdc693d;p=thirdparty%2Fsamba.git python/samba: PY3 fix can't compare string with int Testing a string against an int value is illegal and is not necessary in this case, this patch removes the problematic test. Signed-off-by: Noel Power Reviewed-by: Andrew Bartlett --- diff --git a/python/samba/getopt.py b/python/samba/getopt.py index db1c1756e4b..094031ddd52 100644 --- a/python/samba/getopt.py +++ b/python/samba/getopt.py @@ -63,9 +63,6 @@ class SambaOptions(optparse.OptionGroup): self._configfile = arg def _set_debuglevel(self, option, opt_str, arg, parser): - if arg < 0: - raise optparse.OptionValueError("invalid %s option value: %s" % - (opt_str, arg)) self._lp.set('debug level', arg) parser.values.debuglevel = arg