diff options
author | Erik Andersen <andersen@codepoet.org> | 1999-12-17 18:44:15 +0000 |
---|---|---|
committer | Erik Andersen <andersen@codepoet.org> | 1999-12-17 18:44:15 +0000 |
commit | 4d1d0113fd3309aac30b2dd1d443bf7c7d5f0a3d (patch) | |
tree | 1d18bbba8f8a1d78d7ff13e7a87ee2aab165125f /archival | |
parent | 6da0ae8183a31d4faab745d534a363c7e66ef864 (diff) |
Reworked the source so it will compile and run under glibc 2.0.7
and linux kernel 2.0.36 (though the dubious reasons why someone
would want to do that defy imagination ;)
-Erik
Diffstat (limited to 'archival')
-rw-r--r-- | archival/gunzip.c | 4 | ||||
-rw-r--r-- | archival/gzip.c | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/archival/gunzip.c b/archival/gunzip.c index a809fed68..61391a33f 100644 --- a/archival/gunzip.c +++ b/archival/gunzip.c @@ -805,7 +805,11 @@ int gunzip_main (int argc, char** argv) } /* Open output fille */ +#if (__GLIBC__ >= 2) && (__GLIBC_MINOR__ >= 1) outFileNum=open( ofname, O_RDWR|O_CREAT|O_EXCL|O_NOFOLLOW); +#else + outFileNum=open( ofname, O_RDWR|O_CREAT|O_EXCL); +#endif if (outFileNum < 0) { perror(ofname); do_exit(WARNING); diff --git a/archival/gzip.c b/archival/gzip.c index 983f673e1..76df3ad9a 100644 --- a/archival/gzip.c +++ b/archival/gzip.c @@ -1877,7 +1877,11 @@ int gzip_main(int argc, char ** argv) /* Open output fille */ +#if (__GLIBC__ >= 2) && (__GLIBC_MINOR__ >= 1) outFileNum=open( ofname, O_RDWR|O_CREAT|O_EXCL|O_NOFOLLOW); +#else + outFileNum=open( ofname, O_RDWR|O_CREAT|O_EXCL); +#endif if (outFileNum < 0) { perror(ofname); do_exit(WARNING); |