Commit bdd2d93b authored by R. David Murray's avatar R. David Murray

Revert r88197. I'll refix correctly once there is a test.

parent 14eb4c35
......@@ -377,11 +377,8 @@ class BytesGenerator(Generator):
def _handle_text(self, msg):
# If the string has surrogates the original source was bytes, so
# just write it back out.
payload = msg.get_payload()
if payload is None:
return
if _has_surrogates(payload):
self.write(payload)
if _has_surrogates(msg._payload):
self.write(msg._payload)
else:
super(BytesGenerator,self)._handle_text(msg)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment