diff --git a/patch.py b/patch.py index 45c5a48..535b674 100755 --- a/patch.py +++ b/patch.py @@ -176,7 +176,7 @@ def fromstring(s): """ Parse text string and return PatchSet() object (or False if parsing fails) """ - ps = PatchSet( StringIO(s) ) + ps = PatchSet( StringIO(s.encode()) ) if ps.errors == 0: return ps return False