diff options
author | Damien Miller <djm@mindrot.org> | 2011-12-19 10:51:11 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2011-12-19 10:51:11 +1100 |
commit | 5360dff2a011ab2de10f92450aa9cb10703b9a01 (patch) | |
tree | c4cb11967df524085856eb304fa561acbad1157a /mux.c | |
parent | 47d8115e5347385d55b4a17b026bd131793b9e95 (diff) |
- djm@cvs.openbsd.org 2011/12/02 00:41:56
[mux.c]
fix bz#1948: ssh -f doesn't fork for multiplexed connection.
ok dtucker@
Diffstat (limited to 'mux.c')
-rw-r--r-- | mux.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: mux.c,v 1.31 2011/09/23 07:45:05 markus Exp $ */ | 1 | /* $OpenBSD: mux.c,v 1.32 2011/12/02 00:41:56 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2002-2008 Damien Miller <djm@openbsd.org> | 3 | * Copyright (c) 2002-2008 Damien Miller <djm@openbsd.org> |
4 | * | 4 | * |
@@ -95,6 +95,7 @@ extern Buffer command; | |||
95 | extern volatile sig_atomic_t quit_pending; | 95 | extern volatile sig_atomic_t quit_pending; |
96 | extern char *stdio_forward_host; | 96 | extern char *stdio_forward_host; |
97 | extern int stdio_forward_port; | 97 | extern int stdio_forward_port; |
98 | extern int fork_after_authentication_flag; | ||
98 | 99 | ||
99 | /* Context for session open confirmation callback */ | 100 | /* Context for session open confirmation callback */ |
100 | struct mux_session_confirm_ctx { | 101 | struct mux_session_confirm_ctx { |
@@ -1802,6 +1803,8 @@ mux_client_request_session(int fd) | |||
1802 | if (tty_flag) | 1803 | if (tty_flag) |
1803 | enter_raw_mode(options.request_tty == REQUEST_TTY_FORCE); | 1804 | enter_raw_mode(options.request_tty == REQUEST_TTY_FORCE); |
1804 | 1805 | ||
1806 | if (fork_after_authentication_flag) | ||
1807 | daemon(1, 1); | ||
1805 | /* | 1808 | /* |
1806 | * Stick around until the controlee closes the client_fd. | 1809 | * Stick around until the controlee closes the client_fd. |
1807 | * Before it does, it is expected to write an exit message. | 1810 | * Before it does, it is expected to write an exit message. |