Skip to content

Commit a6c6d7d

Browse files
authored
fix: Profiler should not log "with parent process" unless parent process is non-empty (#3066)
Don't log "with parent process" unless parent process is non-empty
1 parent ee04d25 commit a6c6d7d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Agent/NewRelic/Profiler/Configuration/Configuration.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ namespace NewRelic { namespace Profiler { namespace Configuration {
509509
{
510510
auto isIis = Strings::EndsWith(processName, _X("W3WP.EXE")) || Strings::EndsWith(parentProcessName, _X("W3WP.EXE"));
511511

512-
LogInfo(_X("Process ") + processName + _X(" with parent process ") + parentProcessName + (isIis ? _X(" is") : _X(" is not")) + _X(" IIS."));
512+
LogInfo(_X("Process ") + processName + (parentProcessName == _X("") ? _X("") : _X(" with parent process ") + parentProcessName) + (isIis ? _X(" is") : _X(" is not")) + _X(" IIS."));
513513

514514
return isIis;
515515
}

0 commit comments

Comments
 (0)