do not report yet violations if guithread is not set yet

Without this change, the call to Gtk.Application.Init() would
be reported as a violation itself.

(Detected, and bugfix tested, in MonoDevelop & Banshee)
This commit is contained in:
Andres G. Aragoneses 2012-09-21 21:33:46 +01:00
parent 5e77fdbb24
commit 9eff181e46

View File

@ -63,6 +63,9 @@ simple_method_enter (MonoProfiler *prof, MonoMethod *method)
guithread = current_thread_id;
printf ("*** GUI THREAD INITIALIZED: %u\n", guithread);
}
if (!guithread_set) {
return;
}
if (current_thread_id != guithread &&
!(strcmp (klass_name, "Object")==0 && strcmp (method_name, "Dispose")==0) &&
!(strcmp (klass_name, "Application")==0 && strcmp (method_name, "Invoke")==0) &&