From 82ace39b426a843382a6a809e7b66487c1412494 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 31 Dec 2012 22:27:26 +0300 Subject: Fix code style and compilation under windows. --- src/client.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/client.cpp') diff --git a/src/client.cpp b/src/client.cpp index b21aa6970..ce265ee15 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -707,7 +707,11 @@ void Client::setEnv(const char *const name, const char *const value) { if (!name || !value) return; +#ifdef WIN32 + if (putenv((char*)(std::string(name) + "=" + value).c_str())) +#else if (setenv(name, value, 1)) +#endif logger->log("setenv failed: %s=%s", name, value); } -- cgit v1.2.3-70-g09d2