From eed41c1f126feffafe09737f15d38d4ed338e4cb Mon Sep 17 00:00:00 2001 From: Thomas Wilshaw Date: Thu, 3 Sep 2020 15:25:07 +0100 Subject: [PATCH] Comments --- app/common/commandlineparser.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/common/commandlineparser.cpp b/app/common/commandlineparser.cpp index deaf200ea..3eed80942 100644 --- a/app/common/commandlineparser.cpp +++ b/app/common/commandlineparser.cpp @@ -121,6 +121,9 @@ void CommandLineParser::PrintHelp(const char* filename) if (!basename) { basename = strrchr(filename, '/'); } + // If no slashes are found we are probably running Olive from the executables own directory + // so we set basename equal to the filename (olive-editor.exe). This ensures basename is + // always valid. if (!basename) { basename = filename; path = false;