Python 3 fix & arc cmd line tool fix

This commit is contained in:
Gene Shuman
2017-01-23 14:58:55 -08:00
parent 7f28c44e81
commit 029fb80dc7
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -40,10 +40,10 @@ message = sys.stdin.read()
verbose = '-v' in sys.argv
if verbose:
logging.basicConfig(level=10)
d = dkim.ARC(message)
cv, results, comment = d.verify()
a = dkim.ARC(message)
cv, results, comment = a.verify()
else:
cv, results, comment = arc.verify(message)
cv, results, comment = dkim.arc_verify(message)
print("arc verification: cv=%s %s" % (cv, comment))
if verbose:
+1 -1
View File
@@ -80,6 +80,6 @@ def get_txt(name):
except UnicodeDecodeError:
return None
txt = _get_txt(unicode_name)
if txt:
if type(txt) is str:
txt = txt.encode('utf-8')
return txt