Made sure the ObjC mutex is created before it might first be used.

main
theraven 16 years ago
parent 8efbf98e55
commit 5f48260c6a

@ -542,10 +542,10 @@ __objc_exec_class (Module_t module)
if (! previous_constructors) if (! previous_constructors)
{ {
/* Initialize thread-safe system */ /* Initialize thread-safe system */
INIT_LOCK(objc_runtime_mutex);
__objc_init_thread_system (); __objc_init_thread_system ();
__objc_sync_init(); __objc_sync_init();
__objc_runtime_threads_alive = 1; __objc_runtime_threads_alive = 1;
INIT_LOCK(objc_runtime_mutex);
__objc_init_selector_tables (); __objc_init_selector_tables ();
__objc_init_protocol_table (); __objc_init_protocol_table ();

Loading…
Cancel
Save