summaryrefslogtreecommitdiff
path: root/Modules/binascii.c
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1995-11-14 10:35:19 +0000
committerJack Jansen <jack.jansen@cwi.nl>1995-11-14 10:35:19 +0000
commit5d9579707f353728e7d3e6aa9b9d44b5bb07071d (patch)
treee135f21dc103286e5cec0fdfea0395ed46bc9f9a /Modules/binascii.c
parent40b546d40ebacdc984fa0f8cfd061854f895ccc7 (diff)
downloadcpython-git-5d9579707f353728e7d3e6aa9b9d44b5bb07071d.tar.gz
Allow '@' for ' ' in uuencoded files.
Diffstat (limited to 'Modules/binascii.c')
-rw-r--r--Modules/binascii.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/Modules/binascii.c b/Modules/binascii.c
index cd806723d4..8d4784033a 100644
--- a/Modules/binascii.c
+++ b/Modules/binascii.c
@@ -227,8 +227,11 @@ binascii_a2b_uu(self, args)
*/
this_ch = 0;
} else {
- /* Check the character for legality */
- if ( this_ch < ' ' || this_ch > (' ' + 63)) {
+ /* Check the character for legality
+ ** The 64 in stead of the expected 63 is because there are a few
+ ** uuencodes out there that use '@' as zero in stead of space.
+ */
+ if ( this_ch < ' ' || this_ch > (' ' + 64)) {
PyErr_SetString(Error, "Illegal char");
Py_DECREF(rv);
return NULL;