summaryrefslogtreecommitdiffhomepage
path: root/svr-agentfwd.c
diff options
context:
space:
mode:
Diffstat (limited to 'svr-agentfwd.c')
-rw-r--r--svr-agentfwd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/svr-agentfwd.c b/svr-agentfwd.c
index 4c49e45..fd068fe 100644
--- a/svr-agentfwd.c
+++ b/svr-agentfwd.c
@@ -103,10 +103,11 @@ static void agentaccept(struct Listener * listener) {
fd = accept(listener->sock, NULL, NULL);
if (fd < 0) {
+ TRACE(("accept failed"));
return;
}
- if (send_msg_channel_open_agent(listener->sock) != DROPBEAR_SUCCESS) {
+ if (send_msg_channel_open_agent(fd) != DROPBEAR_SUCCESS) {
close(fd);
}