diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2014-02-11 20:18:28 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2014-02-11 20:18:28 +0800 |
commit | 5812a64b37d450c3df6b7825af9316b10975b5cd (patch) | |
tree | f68dccbd088cb8bfbef12d180a13cc482fd6f1c2 | |
parent | 462d5e0eb97d36c4ee21f2b45a19ce69eee26334 (diff) | |
download | pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar.gz pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar.bz2 pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar.lz pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar.xz pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.tar.zst pttbbs-5812a64b37d450c3df6b7825af9316b10975b5cd.zip |
Enable strip_zero in big5.decode.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk@5927 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | pttbbs/util/pyutil/big5.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pttbbs/util/pyutil/big5.py b/pttbbs/util/pyutil/big5.py index 90fbe7c7..e8919f2d 100644 --- a/pttbbs/util/pyutil/big5.py +++ b/pttbbs/util/pyutil/big5.py @@ -12,7 +12,7 @@ def decode(s, strip_zero=True): b = ord(i) if b >= 0x80: continue - if b == 0: + if (b == 0) and strip_zero: break ret += unichr(big5_tbl.b2u_table[b]) b = 0 |