aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Crute <mike@crute.us>2017-09-30 22:31:54 +0000
committerMike Crute <mike@crute.us>2017-09-30 23:09:18 +0000
commitcb0230e60ed540b549f391c31b34cca3305d9507 (patch)
treebe858b137813e05fef7163b45966db1bcac63012
parent6b97dd6d8a01ff56b7f70a160fbaf59ddec5c60f (diff)
downloadpydora-cb0230e60ed540b549f391c31b34cca3305d9507.tar.bz2
pydora-cb0230e60ed540b549f391c31b34cca3305d9507.tar.xz
pydora-cb0230e60ed540b549f391c31b34cca3305d9507.zip
Fix python2.7 regression
-rw-r--r--pandora/transport.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pandora/transport.py b/pandora/transport.py
index 94e5f6d..6693824 100644
--- a/pandora/transport.py
+++ b/pandora/transport.py
@@ -255,7 +255,7 @@ class BlowfishCryptor(object):
255 def _add_padding(data): 255 def _add_padding(data):
256 block_size = Blowfish.block_size 256 block_size = Blowfish.block_size
257 pad_size = len(data) % block_size 257 pad_size = len(data) % block_size
258 padding = bytes(chr(pad_size) * (block_size - pad_size), "ascii") 258 padding = (chr(pad_size) * (block_size - pad_size)).encode("ascii")
259 return data.encode("utf-8") + padding 259 return data.encode("utf-8") + padding
260 260
261 @staticmethod 261 @staticmethod