[Socket] Move IOControl related methods to their region
[mono.git] / mono / metadata / domain.c
index c251ff9d99c64d92c6859ae76474027da4d8f18b..801d58e41629f0b6beefca40b87d97271b9d2ba1 100755 (executable)
@@ -119,8 +119,6 @@ static const MonoRuntimeInfo *current_runtime = NULL;
 /* This is the list of runtime versions supported by this JIT.
  */
 static const MonoRuntimeInfo supported_runtimes[] = {
-       {"v2.0.50215","2.0", { {2,0,0,0}, { 8,0,0,0}, {3,5,0,0}, {3,0,0,0} } },
-       {"v2.0.50727","2.0", { {2,0,0,0}, { 8,0,0,0}, {3,5,0,0}, {3,0,0,0} } },
        {"v4.0.30319","4.5", { {4,0,0,0}, {10,0,0,0}, {4,0,0,0}, {4,0,0,0} } },
        {"v4.0.30128","4.0", { {4,0,0,0}, {10,0,0,0}, {4,0,0,0}, {4,0,0,0} } },
        {"v4.0.20506","4.0", { {4,0,0,0}, {10,0,0,0}, {4,0,0,0}, {4,0,0,0} } },
@@ -602,6 +600,9 @@ mono_init_internal (const char *filename, const char *exe_filename, const char *
        }
        mono_defaults.corlib = mono_assembly_get_image (ass);
 
+       /* might be NULL if System.dll is not yet loaded */
+       mono_defaults.system = mono_image_loaded ("System");
+
        mono_defaults.object_class = mono_class_from_name (
                 mono_defaults.corlib, "System", "Object");
        g_assert (mono_defaults.object_class != 0);
@@ -1917,3 +1918,17 @@ mono_get_aot_cache_config (void)
 {
        return &aot_cache_config;
 }
+
+void
+mono_domain_lock (MonoDomain *domain)
+{
+       MONO_PREPARE_BLOCKING
+       mono_locks_acquire (&(domain)->lock, DomainLock);
+       MONO_FINISH_BLOCKING
+}
+
+void
+mono_domain_unlock (MonoDomain *domain)
+{
+       mono_locks_release (&(domain)->lock, DomainLock);
+}