diff options
Diffstat (limited to 'session.c')
-rw-r--r-- | session.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -169,7 +169,8 @@ do_authenticated(struct passwd * pw) | |||
169 | * authentication. | 169 | * authentication. |
170 | */ | 170 | */ |
171 | alarm(0); | 171 | alarm(0); |
172 | close(startup_pipe); | 172 | if (startup_pipe != -1) |
173 | close(startup_pipe); | ||
173 | 174 | ||
174 | /* | 175 | /* |
175 | * Inform the channel mechanism that we are the server side and that | 176 | * Inform the channel mechanism that we are the server side and that |
@@ -1792,7 +1793,8 @@ do_authenticated2(void) | |||
1792 | * authentication. | 1793 | * authentication. |
1793 | */ | 1794 | */ |
1794 | alarm(0); | 1795 | alarm(0); |
1795 | close(startup_pipe); | 1796 | if (startup_pipe != -1) |
1797 | close(startup_pipe); | ||
1796 | server_loop2(); | 1798 | server_loop2(); |
1797 | if (xauthfile) | 1799 | if (xauthfile) |
1798 | xauthfile_cleanup_proc(NULL); | 1800 | xauthfile_cleanup_proc(NULL); |