зеркало из https://github.com/mozilla/pjs.git
added dumpMemoryLeaks(). bug=15906, r=hyatt
This commit is contained in:
Родитель
488348911c
Коммит
c35d65d7c5
|
@ -1181,3 +1181,13 @@ function dumpObject( anObject, prefix ) {
|
|||
function dumpExpr( expr ) {
|
||||
dump( expr+"="+eval(expr)+"\n" );
|
||||
}
|
||||
|
||||
var leakDetector = null;
|
||||
|
||||
// Dumps current set of memory leaks.
|
||||
function dumpMemoryLeaks() {
|
||||
if (leakDetector == null)
|
||||
leakDetector = createInstance("component://netscape/xpcom/leakdetector", "nsILeakDetector");
|
||||
if (leakDetector != null)
|
||||
leakDetector.dumpLeaks();
|
||||
}
|
||||
|
|
|
@ -1181,3 +1181,13 @@ function dumpObject( anObject, prefix ) {
|
|||
function dumpExpr( expr ) {
|
||||
dump( expr+"="+eval(expr)+"\n" );
|
||||
}
|
||||
|
||||
var leakDetector = null;
|
||||
|
||||
// Dumps current set of memory leaks.
|
||||
function dumpMemoryLeaks() {
|
||||
if (leakDetector == null)
|
||||
leakDetector = createInstance("component://netscape/xpcom/leakdetector", "nsILeakDetector");
|
||||
if (leakDetector != null)
|
||||
leakDetector.dumpLeaks();
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче