diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2009-03-09 14:40:45 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2009-03-09 14:40:45 +0000 |
commit | 71d13bca551f5629a0c903807028088cc97bfc0e (patch) | |
tree | 731494f846997d4bbaec97e63897c59f4ac276c4 /winsup/cygwin/include | |
parent | c47426aedbb385c8717fdf4e029bcf5c3e70bc53 (diff) | |
download | cygnal-71d13bca551f5629a0c903807028088cc97bfc0e.tar.gz cygnal-71d13bca551f5629a0c903807028088cc97bfc0e.tar.bz2 cygnal-71d13bca551f5629a0c903807028088cc97bfc0e.zip |
* fhandler.h (fhandler_socket::wait_for_events): Take additional
parameter "dontwait".
* fhandler_socket.cc (fhandler_socket::wait_for_events): Act as if the
socket is non-blocking if dontwait is true.
(fhandler_socket::recv_internal): Use incoming MSG_DONTWAIT flag to
set the wait_for_events dontwait parameter.
(fhandler_socket::send_internal): Ditto. Optimize code slightly.
* include/cygwin/socket.h (MSG_DONTWAIT): Define.
* include/cygwin/version.h: Bump API minor number.
Diffstat (limited to 'winsup/cygwin/include')
-rw-r--r-- | winsup/cygwin/include/cygwin/socket.h | 3 | ||||
-rw-r--r-- | winsup/cygwin/include/cygwin/version.h | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/winsup/cygwin/include/cygwin/socket.h b/winsup/cygwin/include/cygwin/socket.h index f521f0ad8..fdb842dc6 100644 --- a/winsup/cygwin/include/cygwin/socket.h +++ b/winsup/cygwin/include/cygwin/socket.h @@ -1,6 +1,6 @@ /* cygwin/socket.h - Copyright 1999, 2000, 2001, 2005, 2006, 2007 Red Hat, Inc. + Copyright 1999, 2000, 2001, 2005, 2006, 2007, 2009 Red Hat, Inc. This file is part of Cygwin. @@ -191,6 +191,7 @@ struct OLD_msghdr #define MSG_PEEK 0x2 /* peek at incoming message */ #define MSG_DONTROUTE 0x4 /* send without using routing tables */ #define MSG_WAITALL 0x8 /* wait for all requested bytes */ +#define MSG_DONTWAIT 0x10 /* selective non-blocking operation */ #define MSG_NOSIGNAL 0x20 /* Don't raise SIGPIPE */ #define MSG_TRUNC 0x0100 /* Normal data truncated */ #define MSG_CTRUNC 0x0200 /* Control data truncated */ diff --git a/winsup/cygwin/include/cygwin/version.h b/winsup/cygwin/include/cygwin/version.h index d0293c096..6a321f98d 100644 --- a/winsup/cygwin/include/cygwin/version.h +++ b/winsup/cygwin/include/cygwin/version.h @@ -352,12 +352,13 @@ details. */ 201: Export wprintf, fwprintf, swprintf, vwprintf, vfwprintf, vswprintf. 202: Export gethostbyname2. 203: Export wcsftime. + 204: recv/send flag MSG_DONTWAIT added. */ /* Note that we forgot to bump the api for ualarm, strtoll, strtoull */ #define CYGWIN_VERSION_API_MAJOR 0 -#define CYGWIN_VERSION_API_MINOR 203 +#define CYGWIN_VERSION_API_MINOR 204 /* There is also a compatibity version number associated with the shared memory regions. It is incremented when incompatible |