Bug 732308 - fix potential leak in xpcshell/head.js (r=jmaher)

This commit is contained in:
Luke Wagner 2012-03-02 09:36:53 -08:00
parent 7ab87937cc
commit 55d77bd4a6

View File

@ -778,6 +778,13 @@ function do_get_profile() {
};
dirSvc.QueryInterface(Components.interfaces.nsIDirectoryService)
.registerProvider(provider);
// The methods of 'provider' will entrain this scope so null out everything
// to avoid spurious leak reports.
env = null;
profd = null;
dirSvc = null;
provider = null;
return file.clone();
}