From a21974367ce9337fb599782ae667e6488d2a34d4 Mon Sep 17 00:00:00 2001 From: Vincent Torri Date: Tue, 28 May 2019 11:37:03 -0400 Subject: [PATCH] Evil: fix infinite loop with setlocale Summary: evil_setlocale was defined as setlocale in evil_private.h *before* evil_setlocale, hence evil_setlocale was calling itself. The solution was to not call evil_private.h in evil_locale.c Test Plan: compialtion and elementary_test Reviewers: zmike, raster, cedric Reviewed By: zmike Subscribers: #reviewers, #committers Tags: #efl Maniphest Tasks: T7985 Differential Revision: https://phab.enlightenment.org/D9030 --- src/lib/evil/evil_locale.c | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/src/lib/evil/evil_locale.c b/src/lib/evil/evil_locale.c index a4d056ad93..15610da6a6 100644 --- a/src/lib/evil/evil_locale.c +++ b/src/lib/evil/evil_locale.c @@ -6,7 +6,27 @@ #include #include -#include "evil_private.h" +#ifndef WIN32_LEAN_AND_MEAN +# define WIN32_LEAN_AND_MEAN +#endif +#include +#undef WIN32_LEAN_AND_MEAN + +#ifdef EAPI +# undef EAPI +#endif + +#ifdef EFL_BUILD +# ifdef DLL_EXPORT +# define EAPI __declspec(dllexport) +# else +# define EAPI +# endif +#else +# define EAPI __declspec(dllimport) +#endif + +#include "evil_locale.h" /* LC_MESSAGES */ /* * LOCALE_SISO639LANGNAME and LOCALE_SISO3166CTRYNAME need at least a buffer