aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/ChangeLog6
-rw-r--r--winsup/cygwin/fhandler_socket.cc1
2 files changed, 7 insertions, 0 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 283bc7f..82b283b 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,9 @@
+2005-06-12 Corinna Vinschen <corinna@vinschen.de>
+
+ * fhandler_socket.cc (fhandler_socket::recvmsg): Avoid SEGV in OpenSSH
+ when trying to pass file descriptor by setting msg->msg_accrightslen
+ to 0.
+
2005-06-11 Christopher Faylor <cgf@timesys.com>
* Makefile.in: Avoid initial heap allocation since cygwin has its own
diff --git a/winsup/cygwin/fhandler_socket.cc b/winsup/cygwin/fhandler_socket.cc
index 31800e4..ced4503 100644
--- a/winsup/cygwin/fhandler_socket.cc
+++ b/winsup/cygwin/fhandler_socket.cc
@@ -1063,6 +1063,7 @@ fhandler_socket::recvmsg (struct msghdr *msg, int flags, ssize_t tot)
go ahead recv'ing the normal data blocks. Otherwise start
special handling for descriptor passing. */
/*TODO*/
+ msg->msg_accrightslen = 0;
}
struct iovec *const iov = msg->msg_iov;