evil: Define environ macro when using VS based on UCRT definition

Summary:
Microsoft Visual Studio defines _environ, but not environ. Create
a macro #define environ _environ like other analogous solutions

Co-authored-by: Lucas Cavalcante de Sousa <lucks.sousa@gmail.com>

Reviewers: vtorri, woohyun, joaoantoniocardoso, lucas, jptiz

Reviewed By: jptiz

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12209
This commit is contained in:
João Antônio Cardoso 2020-12-09 16:51:32 -03:00 committed by Felipe Magno de Almeida
parent 138e9e5294
commit 2b08306875
2 changed files with 8 additions and 1 deletions

View File

@ -16,7 +16,7 @@
#if defined (__FreeBSD__) || defined (__OpenBSD__)
# include <dlfcn.h>
static char ***_dl_environ;
#else
#elif !defined(_MSC_VER)
extern char **environ;
#endif

View File

@ -14,6 +14,13 @@
* @{
*/
/*
* Define environ for native windows based on UCRT
*
*/
#ifdef _MSC_VER
# define environ _environ
#endif
/*
* Environment variable related functions