summaryrefslogtreecommitdiff
path: root/rpmio
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2002-02-07 16:55:01 +0000
committerjbj <devnull@localhost>2002-02-07 16:55:01 +0000
commit380b21d69e86fc34f9785369043b3933ec0df645 (patch)
tree9247ff0902be3b3af3c1c04c9b2825d56420fc36 /rpmio
parent56de656223afce0b119f4c44addaaa5642f3ed52 (diff)
downloadlibrpm-tizen-380b21d69e86fc34f9785369043b3933ec0df645.tar.gz
librpm-tizen-380b21d69e86fc34f9785369043b3933ec0df645.tar.bz2
librpm-tizen-380b21d69e86fc34f9785369043b3933ec0df645.zip
Sync with rpm-4.0.4.
CVS patchset: 5303 CVS date: 2002/02/07 16:55:01
Diffstat (limited to 'rpmio')
-rw-r--r--rpmio/rpmio.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
index 0c4a90d64..c39dfdc9c 100644
--- a/rpmio/rpmio.c
+++ b/rpmio/rpmio.c
@@ -487,6 +487,10 @@ DBGIO(fd, (stderr, "==>\tfdClose(%p) rc %lx %s\n", (fd ? fd : NULL), (unsigned l
fdno = open(path, flags, mode);
if (fdno < 0) return NULL;
+ if (fcntl(fdno, F_SETFD, FD_CLOEXEC)) {
+ (void) close(fdno);
+ return NULL;
+ }
fd = fdNew("open (fdOpen)");
fdSetFdno(fd, fdno);
fd->flags = flags;