Status

()

Core
XPCOM
RESOLVED DUPLICATE of bug 87680
17 years ago
9 years ago

People

(Reporter: Cathleen, Assigned: Ray Whitmer)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

17 years ago
so, in doing fixes for bug 85770, I have uncovered an issue where getting 
registry service will cause assertion in xpinstall context, saying that 
nsRegistry not thread-safe... 

The story is that xpinstall is running on a seperate thread, not on the main UI 
thread, so that while an install/updater is running, xpinstall will not block 
the main UI thread to stop the entire world when a xpi-updater/smartupdate is 
doing software upgrade.  So now, if you try to get registry service on a 
seperate thread, like xpinstall, assertion happens, and here is the stack trace:

nsDebug::Assertion(const char * 0x100f3900, const char * 0x100e31a0, const char 
* 0x100e317c, int 528) line 290 + 13 bytes 
NS_CheckThreadSafe(void * 0x00482e50, const char * 0x100f3900) line 528 + 34 
bytes 
nsRegistry::AddRef(nsRegistry * const 0x00d03260) line 345 + 57 bytes 
nsRegistry::QueryInterface(nsRegistry * const 0x00d03260, const nsID & {...}, 
void * * 0x0487ec94) line 345 + 139 bytes 
nsServiceManagerImpl::GetService(nsServiceManagerImpl * const 0x00485b60, const 
nsID & {...}, const nsID & {...}, nsISupports * *
0x0487ed28, nsIShutdownListener * 0x00000000) line 318 + 25 bytes 
nsServiceManager::GetService(const nsID & {...}, const nsID & {...}, nsISupports 
* * 0x0487ed28, nsIShutdownListener *
0x00000000) line 560 
nsGetServiceByCID::operator()(const nsID & {...}, void * * 0x0487ed28) line 44 + 
22 bytes 
nsCOMPtr<nsIRegistry>::assign_from_helper(const nsCOMPtr_helper & {...}, const 
nsID & {...}) line 971 + 18 bytes 
nsCOMPtr<nsIRegistry>::nsCOMPtr<nsIRegistry>(const nsCOMPtr_helper & {...}) line 
553 
nsInstall::FinalizeInstall(int * 0x0487effc) line 867 + 39 bytes 
InstallFinalizeInstall(JSContext * 0x042f8170, JSObject * 0x02a666a8, unsigned 
int 0, long * 0x02b1ab78, long * 0x0487f0e0) line 841
+ 12 bytes 
js_Invoke(JSContext * 0x042f8170, unsigned int 0, unsigned int 0) line 807 + 23 
bytes 
js_Interpret(JSContext * 0x042f8170, long * 0x0487ff1c) line 2702 + 15 bytes 
js_Execute(JSContext * 0x042f8170, JSObject * 0x02a666a8, JSScript * 0x04327b90, 
JSStackFrame * 0x00000000, unsigned int 0,
long * 0x0487ff1c) line 986 + 13 bytes 
JS_EvaluateUCScriptForPrincipals(JSContext * 0x042f8170, JSObject * 0x02a666a8, 
JSPrincipals * 0x00000000, const unsigned
short * 0x02ada028, unsigned int 744, const char * 0x00000000, unsigned int 0, 
long * 0x0487ff1c) line 3273 + 25 bytes 
JS_EvaluateUCScript(JSContext * 0x042f8170, JSObject * 0x02a666a8, const 
unsigned short * 0x02ada028, unsigned int 744, const
char * 0x00000000, unsigned int 0, long * 0x0487ff1c) line 3255 + 35 bytes 
JS_EvaluateScript(JSContext * 0x042f8170, JSObject * 0x02a666a8, const char * 
0x042fac80, unsigned int 744, const char *
0x00000000, unsigned int 0, long * 0x0487ff1c) line 3222 + 33 bytes 
RunInstallOnThread(void * 0x042ef050) line 438 + 30 bytes 
_PR_NativeRunThread(void * 0x042ee260) line 399 + 13 bytes 
_threadstartex(void * 0x042edf80) line 212 + 13 bytes 
KERNEL32! 77e92ca8()
(Reporter)

Comment 1

17 years ago
oops, a dup of 87680

*** This bug has been marked as a duplicate of 87680 ***
Status: NEW → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → DUPLICATE

Updated

9 years ago
Component: XPCOM Registry → XPCOM
QA Contact: rayw → xpcom
You need to log in before you can comment on or make changes to this bug.