diff options
author | Egor Duda <deo@logos-m.ru> | 2001-10-11 09:46:21 +0000 |
---|---|---|
committer | Egor Duda <deo@logos-m.ru> | 2001-10-11 09:46:21 +0000 |
commit | 5844588b7484d9af135f7cb3b3af3ae71ce85b7b (patch) | |
tree | b0f0395cc1290b29c55d95f872ab3ba00ab4d55e /winsup/cygwin/net.cc | |
parent | f6a85cddc845c72ed31295c5edbcc4dcb82b8dab (diff) | |
download | cygnal-5844588b7484d9af135f7cb3b3af3ae71ce85b7b.tar.gz cygnal-5844588b7484d9af135f7cb3b3af3ae71ce85b7b.tar.bz2 cygnal-5844588b7484d9af135f7cb3b3af3ae71ce85b7b.zip |
* net.cc (cygwin_sendto): Use correct socket address when sending
data to AF_UNIX socket.
Diffstat (limited to 'winsup/cygwin/net.cc')
-rw-r--r-- | winsup/cygwin/net.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/winsup/cygwin/net.cc b/winsup/cygwin/net.cc index 840ecc748..d32cfc1d9 100644 --- a/winsup/cygwin/net.cc +++ b/winsup/cygwin/net.cc @@ -625,7 +625,7 @@ cygwin_sendto (int fd, { debug_printf ("Fallback to winsock 1 sendto call"); if ((res = sendto (h->get_socket (), (const char *) buf, len, flags, - to, tolen)) == SOCKET_ERROR) + (sockaddr *) &sin, tolen)) == SOCKET_ERROR) { set_winsock_errno (); res = -1; @@ -636,7 +636,7 @@ cygwin_sendto (int fd, WSABUF wsabuf = { len, (char *) buf }; DWORD ret = 0; if (WSASendTo (h->get_socket (), &wsabuf, 1, &ret, (DWORD)flags, - to, tolen, ovr, NULL) != SOCKET_ERROR) + (sockaddr *) &sin, tolen, ovr, NULL) != SOCKET_ERROR) res = ret; else if ((res = WSAGetLastError ()) != WSA_IO_PENDING) { |