diff options
author | Luboš Luňák <l.lunak@centrum.cz> | 2018-01-26 08:47:30 +0100 |
---|---|---|
committer | Joel Rosdahl <joel@rosdahl.net> | 2018-01-28 14:56:13 +0100 |
commit | 410f41332e1c232de74b816b078da9812a2e3024 (patch) | |
tree | 6b402c04b7f8df347d09c1f5f9658625fe909fb6 | |
parent | 51d169e48df1dc6a9407c18eb7b23650065a4f5e (diff) | |
download | ccache-410f41332e1c232de74b816b078da9812a2e3024.tar.gz |
Fix broken UNCACHED_ERR_FD
It shouldn't be closed on exec since that's exactly the point, to leak
it to whatever ccache calls.
-rw-r--r-- | ccache.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -3138,11 +3138,11 @@ static void setup_uncached_err(void) { int uncached_fd = dup(2); - set_cloexec_flag(uncached_fd); if (uncached_fd == -1) { cc_log("dup(2) failed: %s", strerror(errno)); failed(); } + // Leak the file descriptor. // Leak a pointer to the environment. char *buf = format("UNCACHED_ERR_FD=%d", uncached_fd); |