Treat 'end\0', 'end\n', 'end\r\n' as trailer line, see rev 1.2
This commit is contained in:
parent
ecb2d8d8e0
commit
adc9806068
@ -255,7 +255,9 @@ decode2(flag)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!fgets(buf, sizeof(buf), stdin) || strncmp(buf, "end", 3) || (buf[3] && buf[3] != '\n')) {
|
if (fgets(buf, sizeof(buf), stdin) == NULL ||
|
||||||
|
(strcmp(buf, "end") && strcmp(buf, "end\n") &&
|
||||||
|
strcmp(buf, "end\r\n"))) {
|
||||||
(void)fprintf(stderr, "uudecode: %s: no \"end\" line.\n",
|
(void)fprintf(stderr, "uudecode: %s: no \"end\" line.\n",
|
||||||
filename);
|
filename);
|
||||||
return(1);
|
return(1);
|
||||||
|
Loading…
Reference in New Issue
Block a user