summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Friedl <markus@cvs.openbsd.org>2001-06-05 10:24:33 +0000
committerMarkus Friedl <markus@cvs.openbsd.org>2001-06-05 10:24:33 +0000
commit11800b0dcfcd2aa549a9e5cab3996f58641813b3 (patch)
tree8fcf4b2ee1e7599e9a1339240252b8022061e932
parentd73611b6b7c99aa0e7283722f6c0ca14d17dcd4c (diff)
don't delete the auth socket in channel_stop_listening()
auth_sock_cleanup_proc() will take care of this.
-rw-r--r--usr.bin/ssh/channels.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/ssh/channels.c b/usr.bin/ssh/channels.c
index a7f83f60459..e2f5178dd96 100644
--- a/usr.bin/ssh/channels.c
+++ b/usr.bin/ssh/channels.c
@@ -40,7 +40,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: channels.c,v 1.123 2001/06/04 21:59:42 markus Exp $");
+RCSID("$OpenBSD: channels.c,v 1.124 2001/06/05 10:24:32 markus Exp $");
#include "ssh.h"
#include "ssh1.h"
@@ -352,7 +352,7 @@ channel_stop_listening()
switch (c->type) {
case SSH_CHANNEL_AUTH_SOCKET:
close(c->sock);
- unlink(c->path);
+ /* auth_sock_cleanup_proc deletes the socket */
channel_free(c);
break;
case SSH_CHANNEL_PORT_LISTENER:
@@ -2804,6 +2804,7 @@ auth_input_request_forwarding(struct passwd * pw)
if (nc == NULL) {
error("auth_input_request_forwarding: channel_new failed");
auth_sock_cleanup_proc(pw);
+ fatal_remove_cleanup(auth_sock_cleanup_proc, pw);
close(sock);
return 0;
}