Bug 496774 XPCJSRuntime::XPCJSRuntime shouldn't touch mJSRuntime without null checking something

r=bent sr=jst
This commit is contained in:
timeless@mozdev.org 2009-07-22 17:31:03 -05:00
parent a8ef15292d
commit eaa72f0137

View File

@ -1099,11 +1099,13 @@ XPCJSRuntime::XPCJSRuntime(nsXPConnect* aXPConnect)
xpc_InstallJSDebuggerKeywordHandler(mJSRuntime);
#endif
AutoLockJSGC lock(mJSRuntime);
if (mWatchdogWakeup) {
AutoLockJSGC lock(mJSRuntime);
mWatchdogThread = PR_CreateThread(PR_USER_THREAD, WatchdogMain, this,
PR_PRIORITY_NORMAL, PR_LOCAL_THREAD,
PR_UNJOINABLE_THREAD, 0);
mWatchdogThread = PR_CreateThread(PR_USER_THREAD, WatchdogMain, this,
PR_PRIORITY_NORMAL, PR_LOCAL_THREAD,
PR_UNJOINABLE_THREAD, 0);
}
}
// static