summaryrefslogtreecommitdiff
path: root/ext/gdbm
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-11-13 14:22:17 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-11-13 14:22:17 +0000
commit4b01d611dbd7911f3f68f1a8b4666125bceaf25b (patch)
tree929827af4f9aa5d91a21c9aa9ec8cdaa4ff1293b /ext/gdbm
parentabe61eb0d136581d031fd8694ec8682820bba722 (diff)
* ext/gdbm/gdbm.c (fgdbm_reorganize): set close-on-exec flag after
gdbm_reorganize(). gdbm_reorganize() opens a new database internally. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/gdbm')
-rw-r--r--ext/gdbm/gdbm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/gdbm/gdbm.c b/ext/gdbm/gdbm.c
index 00fbac9..328feef 100644
--- a/ext/gdbm/gdbm.c
+++ b/ext/gdbm/gdbm.c
@@ -1052,6 +1052,7 @@ fgdbm_reorganize(VALUE obj)
rb_gdbm_modify(obj);
GetDBM2(obj, dbmp, dbm);
gdbm_reorganize(dbm);
+ rb_fd_fix_cloexec(gdbm_fdesc(dbm));
return obj;
}