blob: 48a62e88af0895f9efb8379315850226261667ce (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
From a958624be229315ab57017040ef15c5ae072d1ac Mon Sep 17 00:00:00 2001
From: Matthias Kerestesch <mail@kerestesch.de>
Date: Sat, 18 May 2013 23:01:35 +0200
Subject: [PATCH] libssh2_agent_init: init ->fd to LIBSSH2_INVALID_SOCKET
... previously it was left at 0 which is a valid file descriptor!
Bug: https://trac.libssh2.org/ticket/265
Fixes #265
Upstream-commit: 1ad20ac7d3e21d091e7cfec58fda0afdc359360a
---
src/agent.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/agent.c b/src/agent.c
index 1c65149..a8a5025 100644
--- a/src/agent.c
+++ b/src/agent.c
@@ -652,6 +652,7 @@ libssh2_agent_init(LIBSSH2_SESSION *session)
return NULL;
}
memset(agent, 0, sizeof *agent);
+ agent->fd = LIBSSH2_INVALID_SOCKET;
agent->session = session;
_libssh2_list_init(&agent->head);
--
2.1.0
|