From 9407a5fe76962292901e0cea5ca7d3e3def289c5 Mon Sep 17 00:00:00 2001 From: Felipe Magno de Almeida Date: Tue, 15 Dec 2020 15:44:36 -0300 Subject: evil: Add STDIO FILENO macros for compatibility with MSVC --- src/lib/evil/evil_unistd.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/lib/evil/evil_unistd.h b/src/lib/evil/evil_unistd.h index 9f7b324af9..24c6d7c88f 100644 --- a/src/lib/evil/evil_unistd.h +++ b/src/lib/evil/evil_unistd.h @@ -16,6 +16,7 @@ #ifdef _MSC_VER +#include #include // for read, write, access, close #define execvp _ucrt_execvp // overriding execvp below @@ -29,6 +30,10 @@ EVIL_API int execvp(const char *file, char *const argv[]); #define X_OK 0 /* execute permission, originally '1', just a bypass here*/ #define F_OK 0 /* Test for existence. */ +# define STDIN_FILENO _fileno(stdin) +# define STDOUT_FILENO _fileno(stdout) +# define STDERR_FILENO _fileno(stderr) + #endif // _MSC_VER /* -- cgit v1.2.1