bugfix for issue #457: pattern %z (process id) can not be padded/truncated

This commit is contained in:
Jan Peter Stotz 2017-03-27 14:26:02 +02:00
parent 406084ab3a
commit 2c7cbf0d41

View File

@ -249,7 +249,7 @@ function patternLayout(pattern, tokens, timezoneOffset) {
}
function pid(loggingEvent) {
return loggingEvent && loggingEvent.pid ? loggingEvent.pid : process.pid;
return loggingEvent && loggingEvent.pid ? loggingEvent.pid.toString() : process.pid.toString();
}
function clusterInfo(loggingEvent, specifier) {