diff options
Diffstat (limited to 'src/RdFToI.c')
-rw-r--r-- | src/RdFToI.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/RdFToI.c b/src/RdFToI.c index a16af88..28c0c33 100644 --- a/src/RdFToI.c +++ b/src/RdFToI.c @@ -212,7 +212,7 @@ OpenReadFile( mdata->stream.file = (stdin); mdata->type = XPMFILE; } else { - int fd = open(filename, O_RDONLY); + int fd = open(filename, O_RDONLY | O_CLOEXEC); #if defined(NO_ZPIPE) if ( fd < 0 ) return XpmOpenFailed; @@ -229,11 +229,11 @@ OpenReadFile( return (XpmNoMemory); strcpy(compressfile, filename); strcpy(compressfile + len, ext = ".Z"); - fd = open(compressfile, O_RDONLY); + fd = open(compressfile, O_RDONLY | O_CLOEXEC); if ( fd < 0 ) { strcpy(compressfile + len, ext = ".gz"); - fd = open(compressfile, O_RDONLY); + fd = open(compressfile, O_RDONLY | O_CLOEXEC); if ( fd < 0 ) { XpmFree(compressfile); |