Commit 1243ae7f authored by Guido van Rossum's avatar Guido van Rossum

Allow '@' character as end of line padding in uuencode format.

Not sure why this is generated, but this fixes a problem with a
particular file that was received with the following final line:

F-WE<-*A5]AY]%7>8'&!!(_Y<F*55_"*%46"<OFG=>_5(F/\'``!@
parent e3cd151d
......@@ -265,7 +265,9 @@ binascii_a2b_uu(self, args)
*/
while( ascii_len-- > 0 ) {
this_ch = *ascii_data++;
if ( this_ch != ' ' && this_ch != '\n' && this_ch != '\r' ) {
/* Extra '@' may be written as padding in some cases */
if ( this_ch != ' ' && this_ch != '@' &&
this_ch != '\n' && this_ch != '\r' ) {
PyErr_SetString(Error, "Trailing garbage");
Py_DECREF(rv);
return NULL;
......
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