Treat ^end<EOF> as valid terminator (like ^end\n), some encoders (f.e. Eudora)

produce such things.
This commit is contained in:
ache 1996-04-25 14:49:40 +00:00
parent 826192f359
commit 46774261d1

View File

@ -172,7 +172,7 @@ decode()
}
}
}
if (!fgets(buf, sizeof(buf), stdin) || strcmp(buf, "end\n")) {
if (!fgets(buf, sizeof(buf), stdin) || strcmp(buf, "end") || (buf[3] && buf[3] != '\n')) {
(void)fprintf(stderr, "uudecode: %s: no \"end\" line.\n",
filename);
return(1);