Commit 4152a37d authored by Lukáš Tvrdý's avatar Lukáš Tvrdý

First PVS Studio static analyzer bug found

V607 Ownerless expression 'pi.hThread'. kis_crash_handler.cpp 138
parent 6542d0fe
......@@ -135,7 +135,7 @@ static bool startCrashReporter(const HD_CHAR *dumpPath, const HD_CHAR *minidumpI
if (CreateProcessW(NULL, command, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi)) {
CloseHandle( pi.hProcess );
( pi.hThread );
CloseHandle( pi.hThread );
TerminateProcess(GetCurrentProcess(), 1);
}
......@@ -152,7 +152,7 @@ static bool startCrashReporter(const HD_CHAR *dumpPath, const HD_CHAR *minidumpI
abort();
#endif
return true;
#endif
#endif
}
// Copied from Qt's QString class because of weird linking errors
......@@ -201,7 +201,7 @@ KisCrashHandler::KisCrashHandler()
exceptionHandler = new google_breakpad::ExceptionHandler(tempPath.toStdString(), 0,
startCrashReporter, 0,
true);
#endif
#endif
Q_CHECK_PTR(exceptionHandler);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment