--- zip-2.31/fileio.c +++ zip-2.31/fileio.c @@ -860,7 +860,18 @@ } #else strcat(t, "ziXXXXXX"); /* must use lowercase for Linux dos file system */ +#ifdef NO_MKSTEMP return mktemp(t); +#else + { + int fd; + + if ((fd = mkstemp(t)) < 0) + return NULL; + close(fd); + } + return t; +#endif #endif /* NO_MKTEMP */ #endif /* TANDEM */ #endif /* CMS_MVS */