summaryrefslogtreecommitdiffhomepage
path: root/gui/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gui/main.cpp')
-rw-r--r--gui/main.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/gui/main.cpp b/gui/main.cpp
index 4b3e1f14..0ba62ee8 100644
--- a/gui/main.cpp
+++ b/gui/main.cpp
@@ -72,9 +72,12 @@ void add_win32_path()
for (const char* ptr : contents)
{
+ if (ptr == nullptr)
+ continue;
+
strcat_s(env_path, sizeof(env_path), ptr);
- if (ptr == nullptr || ptr[0] == '\0' || env_path[0] == '\0')
+ if (ptr[0] == '\0' || env_path[0] == '\0')
{
qDebug() << "bad path element, debug info:"
<< (ptr == nullptr ? "<null>" : ptr)