summaryrefslogtreecommitdiffhomepage
path: root/windows
diff options
context:
space:
mode:
authorOdd Stranne <odd@mullvad.net>2020-02-18 20:51:32 +0100
committerOdd Stranne <odd@mullvad.net>2020-02-19 21:17:23 +0100
commitea42564b8a1ede8b05856baa9ba28ee35628b18b (patch)
tree8e9b4e105c5e3be1e0bc5591040fbc005ab6c95e /windows
parent47b5079254521f2ddd1d4d0b220a6d36a55801e7 (diff)
downloadmullvadvpn-ea42564b8a1ede8b05856baa9ba28ee35628b18b.tar.xz
mullvadvpn-ea42564b8a1ede8b05856baa9ba28ee35628b18b.zip
WINFW: Remove unnecessary global variable
Diffstat (limited to 'windows')
-rw-r--r--windows/winfw/src/winfw/winfw.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/windows/winfw/src/winfw/winfw.cpp b/windows/winfw/src/winfw/winfw.cpp
index dc0dbe3387..5388c20449 100644
--- a/windows/winfw/src/winfw/winfw.cpp
+++ b/windows/winfw/src/winfw/winfw.cpp
@@ -9,8 +9,6 @@
namespace
{
-uint32_t g_timeout = 0;
-
MullvadLogSink g_logSink = nullptr;
void *g_logSinkContext = nullptr;
@@ -65,14 +63,14 @@ WinFw_Initialize(
}
// Convert seconds to milliseconds.
- g_timeout = timeout * 1000;
+ uint32_t timeout_ms = timeout * 1000;
g_logSink = logSink;
g_logSinkContext = logSinkContext;
try
{
- g_fwContext = new FwContext(g_timeout);
+ g_fwContext = new FwContext(timeout_ms);
}
catch (std::exception &err)
{
@@ -112,14 +110,14 @@ WinFw_InitializeBlocked(
}
// Convert seconds to milliseconds.
- g_timeout = timeout * 1000;
+ uint32_t timeout_ms = timeout * 1000;
g_logSink = logSink;
g_logSinkContext = logSinkContext;
try
{
- g_fwContext = new FwContext(g_timeout, settings);
+ g_fwContext = new FwContext(timeout_ms, settings);
}
catch (std::exception &err)
{