X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fsupport%2Fenvironment.cpp;h=a364725c21173c137c00960c0ba3ea2cc3bb9270;hb=51c380440b0b2d5f04158e67047727ba1f985dc4;hp=3c856d068b7b2b122ad83f752d9e3bba41877331;hpb=9abb7db46800e554f57e865a3e768602ffd9d6f1;p=lyx.git diff --git a/src/support/environment.cpp b/src/support/environment.cpp index 3c856d068b..a364725c21 100644 --- a/src/support/environment.cpp +++ b/src/support/environment.cpp @@ -4,8 +4,8 @@ * Licence details can be found in the file COPYING. * * \author Angus Leeming - * \author João Luis M. Assirati - * \author Lars Gullik Bjønnes + * \author João Luis M. Assirati + * \author Lars Gullik Bjønnes * * Full author contact details are available in file CREDITS. */ @@ -62,7 +62,7 @@ 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); + return ::setenv(name.c_str(), encoded.c_str(), 1) == 0; #elif defined (HAVE_PUTENV) static map varmap; varmap[name] = name + '=' + encoded;