save-cwd: don't leak a file descriptor when the caller execs
authorJames Youngman <jay@gnu.org>
Mon, 29 Mar 2010 10:30:23 +0000 (12:30 +0200)
committerJim Meyering <meyering@redhat.com>
Mon, 29 Mar 2010 10:30:32 +0000 (12:30 +0200)
commit7dfa1250265017223e36c72713a7521421b4d27c
tree4e9f8c8192f97d9e0d29ddde1fdc8087b0f453f6
parent6e0a75f9d908bb6d9f1039d1255d2513eafa9959
save-cwd: don't leak a file descriptor when the caller execs

* lib/save-cwd.c (save_cwd): set the close-on-exec flag for the
saved file descriptor.
* modules/save-cwd (Depends-on): Depend on cloexec.
ChangeLog
lib/save-cwd.c
modules/save-cwd