aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/system/libkvisystem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/system/libkvisystem.cpp')
-rw-r--r--src/modules/system/libkvisystem.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/modules/system/libkvisystem.cpp b/src/modules/system/libkvisystem.cpp
index 6b328059b..00d4179ee 100644
--- a/src/modules/system/libkvisystem.cpp
+++ b/src/modules/system/libkvisystem.cpp
@@ -202,14 +202,15 @@ static bool system_kvs_fnc_getenv(KviKvsModuleFunctionCall *c)
KVSM_PARAMETERS_END(c)
KviQCString szVar = szVariable.toLocal8Bit();
-#ifdef COMPILE_ON_WINDOWS
- QString env = getenv(szVar.data());
- QString def = __tr2qs("No environment variable found, please don't use the %% in the request");
+/*#ifdef COMPILE_ON_WINDOWS
+ QString env= getenv(szVar.data());
+ QString def= __tr2qs("No environment variable found, please don't use the %% in the request");
c->returnValue()->setString(env.isEmpty() ? QString::fromLocal8Bit(env) : QString::fromLocal8Bit(def));
#else
+*/
char * b = kvi_getenv(szVar.data());
c->returnValue()->setString(b ? QString::fromLocal8Bit(b) : QString::null);
-#endif
+//#endif
return true;
}