Skip to content

Commit f2c346f

Browse files
committed
add back PID to dumpfile name
1 parent ac89b1e commit f2c346f

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

lib/cppcheck.cpp

+8-4
Original file line numberDiff line numberDiff line change
@@ -334,10 +334,14 @@ static std::vector<std::string> split(const std::string &str, const std::string
334334
static std::string getDumpFileName(const Settings& settings, const std::string& filename, const std::string &cfgHash = "")
335335
{
336336
std::string extension;
337-
if ((settings.dump || !settings.buildDir.empty()) && !cfgHash.empty())
338-
extension = ".dump";
339-
else
340-
extension = "." + cfgHash + ".dump";
337+
338+
if (!settings.dump && settings.buildDir.empty())
339+
extension += "." + std::to_string(settings.pid);
340+
341+
if (!cfgHash.empty())
342+
extension += "." + cfgHash;
343+
344+
extension += ".dump";
341345

342346
if (!settings.dump && !settings.buildDir.empty())
343347
return AnalyzerInformation::getAnalyzerInfoFile(settings.buildDir, filename, "") + extension;

0 commit comments

Comments
 (0)