-- gzip.c
++ gzip.c
char *base = p;
for (;;) {
*p = (char)get_char();
/* Don't allow embedded names to contain paths. */
if (*p == PATH_SEP
#ifdef PATH_SEP2
|| *p == PATH_SEP2
#endif
#ifdef PATH_SEP3
|| *p == PATH_SEP3
) {
p = base;
continue;
}
if (*p++ == '\0') break;
if (p >= ofname+sizeof(ofname)) {
error("corrupted input -- file name too large");