From b55f17ecb5067f3497c23ec9671ac47d8809e6ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Thu, 11 Oct 2007 06:17:52 +0000 Subject: [PATCH] shut up git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20892 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/support/environment.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/support/environment.cpp b/src/support/environment.cpp index e3469f1fa3..3e1494e016 100644 --- a/src/support/environment.cpp +++ b/src/support/environment.cpp @@ -62,10 +62,9 @@ bool setEnv(string const & name, string const & value) string const encoded = to_local8bit(from_utf8(value)); #if defined (HAVE_SETENV) - return ::setenv(name.c_str(), encoded.c_str(), true) == 0; -#endif + return ::setenv(name.c_str(), encoded.c_str(), true); -#if defined (HAVE_PUTENV) +#elif defined (HAVE_PUTENV) static std::map varmap; string envstr = name + '=' + encoded; @@ -79,9 +78,8 @@ bool setEnv(string const & name, string const & value) delete oldptr; varmap[name] = newptr; return retval == 0; -#endif -#if !(defined HAVE_SETENV) && !(defined HAVE_PUTENV) +#else #error No environment-setting function has been defined. #endif return false;