summary refs log tree commit diff
path: root/src/.gitignore
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2019-01-18 13:01:18 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2019-02-25 12:52:12 +0800
commit48875c1201930d1e71d358eb1cf3eacc166795be (patch)
tree999c367b70ef908863c937944a206fb8b3cdcf7b /src/.gitignore
parentoutput: Fix clang warnings about GNU old-style field designator (diff)
downloaddash-48875c1201930d1e71d358eb1cf3eacc166795be.tar.gz
dash-48875c1201930d1e71d358eb1cf3eacc166795be.zip
redir: Handle nested exec within REALLY_CLOSED redirection
The value of REALLY_CLOSED is used to avoid an unnecessary close(2)
call when restoring redirections.  However, as it stands it can
remove a close(2) call that's actually needed.  This happens when
an enclosed exec(1) command leaves an open file descriptor behind.

This patch fixes this by replacing REALLY_CLOSED with closed_redirs
to track the current status of redirected file descriptors and
leaving redirlist to only handle the previous state of redirected
file descriptors.

Reported-by: Martijn Dekker <martijn@inlv.org>
Fixes: ce0f1900d869 ("[REDIR] Fix redirect restore on saved file...")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions
f3c813eefd5d498a00c0c9d9785bbe5e2b2&follow=1'>Implement graceful shutdownJune McEnroe 2019-10-26Require PASS before USERJune McEnroe Prevent creating a ring consumer without authentication. 2019-10-26Track channel topicsJune McEnroe 2019-10-26Set AWAY when no clients are connectedJune McEnroe 2019-10-26Add flags to request TOPIC and NAMES on client connectJune McEnroe 2019-10-26OopsJune McEnroe 2019-10-26Disconnect client on unknown commandJune McEnroe During registration, no other commands should be sent. Afterwards, only intercepted commands will get parsed. 2019-10-26Allow reading sensitive information from filesJune McEnroe 2019-10-26Add rc scriptJune McEnroe 2019-10-25Add install and uninstall targetsJune McEnroe 2019-10-25Expand documentationJune McEnroe 2019-10-25Add AGPLv3 notice on client registrationJune McEnroe OwO 2019-10-25Rename project pounceJune McEnroe