events: Output the event that is leaking
Signed-off-by: Fedor Indutny <fedor@indutny.com>
This commit is contained in:
parent
b5175003bc
commit
1c0ec71725
@ -173,9 +173,9 @@ EventEmitter.prototype.addListener = function addListener(type, listener) {
|
|||||||
if (m && m > 0 && this._events[type].length > m) {
|
if (m && m > 0 && this._events[type].length > m) {
|
||||||
this._events[type].warned = true;
|
this._events[type].warned = true;
|
||||||
console.error('(node) warning: possible EventEmitter memory ' +
|
console.error('(node) warning: possible EventEmitter memory ' +
|
||||||
'leak detected. %d listeners added. ' +
|
'leak detected. %d %s listeners added. ' +
|
||||||
'Use emitter.setMaxListeners() to increase limit.',
|
'Use emitter.setMaxListeners() to increase limit.',
|
||||||
this._events[type].length);
|
this._events[type].length, type);
|
||||||
console.trace();
|
console.trace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user