UUE decoder fix

This commit is contained in:
Alexander S. Aganichev
2002-10-20 19:42:11 +00:00
parent 26c5617ece
commit 542867d190
5 changed files with 30 additions and 15 deletions

View File

@@ -448,6 +448,7 @@ UUGetPartNo (char *subject, char **where, char **whend)
break;
}
#if 0 /* asa */
/*
* look for the string "part " followed by a number
*/
@@ -487,6 +488,7 @@ UUGetPartNo (char *subject, char **where, char **whend)
}
}
}
#endif /* asa */
/*
* look for the string "part" followed by a number

View File

@@ -688,13 +688,18 @@ ScanData (FILE *datei, char *fname, int *errcode,
* Detect a UUDeview-Style header
*/
if (_FP_strnicmp (line, "_=_ Part ", 9) == 0 &&
if ((_FP_strnicmp (line, "_=_ Part ", 9) == 0 ||
_FP_strnicmp (line, "section ", 8) == 0) &&
result->uudet != YENC_ENCODED) {
if (result->uudet) {
fseek (datei, oldposition, SEEK_SET);
break;
}
result->partno = atoi (line + 8);
if ((ptr = _FP_stristr (line, " of ")) != NULL) {
int maxpno = atoi (ptr + 4);
if(maxpno != 0) result->maxpno = maxpno;
}
if ((ptr = _FP_stristr (line, "of file ")) != NULL) {
ptr += 8;
while (isspace (*ptr)) ptr++;