mirror of
https://github.com/Stichting-MINIX-Research-Foundation/pkgsrc-ng.git
synced 2025-08-16 08:07:20 -04:00
34 lines
1.1 KiB
Plaintext
34 lines
1.1 KiB
Plaintext
$NetBSD: patch-cc,v 1.5 2013/05/29 11:11:12 wiz Exp $
|
|
|
|
Currently mono is not copying the domain default context for some of
|
|
the newly created threads. This leads to some problems with programs
|
|
that use remoting stack, for example monodevelop that is unusable -
|
|
it doesn't compile and run projects. The following hack fixes the
|
|
issue until further investigations for pkgsrc-2010Q3 release.
|
|
|
|
Bug tracking: https://bugzilla.novell.com/show_bug.cgi?id=599485
|
|
|
|
|
|
--- mono/metadata/domain.c.orig 2012-12-05 17:44:34.000000000 +0000
|
|
+++ mono/metadata/domain.c
|
|
@@ -2305,7 +2305,18 @@ mono_context_set (MonoAppContext * new_c
|
|
MonoAppContext *
|
|
mono_context_get (void)
|
|
{
|
|
- return GET_APPCONTEXT ();
|
|
+ MonoAppContext *retval = GET_APPCONTEXT();
|
|
+#ifdef __NetBSD__
|
|
+ /*
|
|
+ * We gotta find out why context is sometime NULL for newly threads
|
|
+ * Until then use default context if it's not set
|
|
+ */
|
|
+ if(retval == NULL) {
|
|
+ retval = ves_icall_System_AppDomain_InternalGetDefaultContext();
|
|
+ mono_context_set(retval);
|
|
+ }
|
|
+#endif
|
|
+ return retval;
|
|
}
|
|
|
|
/* LOCKING: the caller holds the lock for this domain */
|