Improve error reporting as part of solving bug #13546 on MS-Windows.
authorEli Zaretskii <eliz@gnu.org>
Fri, 15 Feb 2013 09:01:13 +0000 (11:01 +0200)
committerEli Zaretskii <eliz@gnu.org>
Fri, 15 Feb 2013 09:01:13 +0000 (11:01 +0200)
commitbcf7fe2aeff7e3aacbfae08ca6001f7615a06709
treecf9259731e5331bd8ca469c5107f13e713d8d28b
parent974c7646ec5b2985a50007c9d599154d667df349
Improve error reporting as part of solving bug #13546 on MS-Windows.

 src/w32.c (sys_socket, sys_bind, sys_connect, sys_gethostname)
 (sys_gethostbyname, sys_getservbyname, sys_getpeername)
 (sys_shutdown, sys_setsockopt, sys_listen, sys_getsockname)
 (sys_accept, sys_recvfrom, sys_sendto, fcntl): In case of failure,
 make sure errno is set to an appropriate value.  (Bug#13546)
 (socket_to_fd): Add assertion against indexing fd_info[] with a
 value that is out of bounds.
 (sys_accept): If fd is negative, do not set up the child_process
 structure for reading.
src/ChangeLog
src/w32.c