[runtime] Format MethodAccessException method names to use the same formating as...
[mono.git] / mono / mini / seq-points.c
index 88f732d9fc350b9e8a6e5b8bda942e9670a3b0c9..8af932a245558b85056f158f6729a71f5df00c0f 100644 (file)
@@ -237,9 +237,11 @@ mono_save_seq_point_info (MonoCompile *cfg)
        // FIXME: dynamic methods
        if (!cfg->compile_aot) {
                mono_domain_lock (domain);
-               // FIXME: How can the lookup succeed ?
+               // FIXME: The lookup can fail if the method is JITted recursively though a type cctor
                if (!g_hash_table_lookup (domain_jit_info (domain)->seq_points, cfg->method_to_register))
                        g_hash_table_insert (domain_jit_info (domain)->seq_points, cfg->method_to_register, cfg->seq_point_info);
+               else
+                       mono_seq_point_info_free (cfg->seq_point_info);
                mono_domain_unlock (domain);
        }