* termios.cc (cfsetspeed): New function.

* cygwin.din (cfsetspeed): Export.
* posix.sgml (std-bsd): Add cfsetspeed.
* include/sys/termios.h (cfsetspeed): Declare.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
This commit is contained in:
Yaakov Selkowitz 2012-11-21 20:13:07 +00:00
parent c342c2eb57
commit beaf1df02c
6 changed files with 27 additions and 1 deletions

View File

@ -1,3 +1,11 @@
2012-11-21 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
* termios.cc (cfsetspeed): New function.
* cygwin.din (cfsetspeed): Export.
* posix.sgml (std-bsd): Add cfsetspeed.
* include/sys/termios.h (cfsetspeed): Declare.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
2012-11-16 Corinna Vinschen <corinna@vinschen.de>
* include/mntent.h: Only include paths.h when building for Cygwin.

View File

@ -208,6 +208,7 @@ cfgetospeed NOSIGFE
cfmakeraw NOSIGFE
cfsetispeed SIGFE
cfsetospeed SIGFE
cfsetspeed SIGFE
chdir SIGFE
_chdir = chdir SIGFE
chmod SIGFE

View File

@ -431,12 +431,13 @@ details. */
260: Export scandirat.
261: Export memrchr.
262: Export getmntent_r.
263: Export cfsetspeed.
*/
/* Note that we forgot to bump the api for ualarm, strtoll, strtoull */
#define CYGWIN_VERSION_API_MAJOR 0
#define CYGWIN_VERSION_API_MINOR 262
#define CYGWIN_VERSION_API_MINOR 263
/* There is also a compatibity version number associated with the
shared memory regions. It is incremented when incompatible

View File

@ -345,6 +345,7 @@ speed_t cfgetispeed(const struct termios *);
speed_t cfgetospeed(const struct termios *);
int cfsetispeed (struct termios *, speed_t);
int cfsetospeed (struct termios *, speed_t);
int cfsetspeed (struct termios *, speed_t);
#ifdef __cplusplus
}

View File

@ -957,6 +957,7 @@ also IEEE Std 1003.1-2008 (POSIX.1-2008).</para>
bindresvport
bindresvport_sa
cfmakeraw
cfsetspeed
daemon
dn_comp
dn_expand

View File

@ -328,6 +328,20 @@ cfsetispeed (struct termios *in_tp, speed_t speed)
return res;
}
/* cfsetspeed: 4.4BSD */
extern "C" int
cfsetspeed (struct termios *in_tp, speed_t speed)
{
struct termios *tp = __tonew_termios (in_tp);
int res;
/* errors come only from unsupported baud rates, so setspeed() would return
identical results in both calls */
if ((res = setspeed (tp->c_ospeed, speed)) == 0)
setspeed (tp->c_ispeed, speed);
__toapp_termios (in_tp, tp);
return res;
}
extern "C" void
cfmakeraw(struct termios *tp)
{