From: Eric Blake Date: Tue, 28 Feb 2012 00:35:56 +0000 (-0700) Subject: tcgetsid: fix cygwin header bug X-Git-Tag: v0.1~1009 X-Git-Url: http://erislabs.net/gitweb/?p=gnulib.git;a=commitdiff_plain;h=c7d52c9898ed0ba5c5e0e7d952d07e4e4da9c70f tcgetsid: fix cygwin header bug Cygwin added tcgetsid in 1.7.10, but with int instead of pid_t: http://cygwin.com/ml/cygwin-patches/2012-q1/msg00031.html For now, since cygwin's pid_t is int, I'm not worrying about correcting the return type. * lib/termios.in.h (includes) [Cygwin]: Ensure pid_t is defined. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index cc12b741d..8f48d9a1c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2012-02-29 Eric Blake + tcgetsid: fix cygwin header bug + * lib/termios.in.h (includes) [Cygwin]: Ensure pid_t is defined. + docs: update cygwin progress * doc/posix-functions/llround.texi (llround): Added in cygwin 1.7.8. diff --git a/lib/termios.in.h b/lib/termios.in.h index 85d1c604f..3836e2d8c 100644 --- a/lib/termios.in.h +++ b/lib/termios.in.h @@ -32,6 +32,12 @@ extern "C" { } #endif +/* On Cygwin 1.7.11, tcgetsid returns int instead of pid_t; at least + they are the same size on that platform. */ +#ifdef __CYGWIN__ +# include +#endif + /* The include_next requires a split double-inclusion guard. */ #if @HAVE_TERMIOS_H@ # @INCLUDE_NEXT@ @NEXT_TERMIOS_H@