From: Steve Dower Date: Wed, 28 Dec 2016 23:41:09 +0000 (-0800) Subject: Issue #28768: Fix implicit declaration of function _setmode. Patch by Masayuki Yamamoto X-Git-Tag: v3.6.1rc1~244 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bfce0f977d20be0781f2b6f201ec309a67bf6099;p=python Issue #28768: Fix implicit declaration of function _setmode. Patch by Masayuki Yamamoto --- diff --git a/Misc/NEWS b/Misc/NEWS index 8ce77785d0..9aebdb53b4 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -103,6 +103,9 @@ Tests Build ----- +- Issue #28768: Fix implicit declaration of function _setmode. Patch by + Masayuki Yamamoto + - Issue #29080: Removes hard dependency on hg.exe from PC/build.bat - Issue #23903: Added missed names to PC/python3.def. diff --git a/Modules/_io/fileio.c b/Modules/_io/fileio.c index 54cfb7fa7d..6854a44e2d 100644 --- a/Modules/_io/fileio.c +++ b/Modules/_io/fileio.c @@ -9,6 +9,9 @@ #ifdef HAVE_SYS_STAT_H #include #endif +#ifdef HAVE_IO_H +#include +#endif #ifdef HAVE_FCNTL_H #include #endif diff --git a/Modules/main.c b/Modules/main.c index d75f64a65f..4cbe376975 100644 --- a/Modules/main.c +++ b/Modules/main.c @@ -7,6 +7,9 @@ #if defined(MS_WINDOWS) || defined(__CYGWIN__) #include +#ifdef HAVE_IO_H +#include +#endif #ifdef HAVE_FCNTL_H #include #endif