[aot] Fix AppDomain.DoAssemblyResolve runtime invoke wrapper
authorAlexander Köplinger <alex.koeplinger@outlook.com>
Fri, 7 Oct 2016 20:04:52 +0000 (22:04 +0200)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Fri, 7 Oct 2016 20:06:22 +0000 (22:06 +0200)
In https://github.com/mono/mono/pull/1528 the DoAssemblyResolve method was changed
from two parameters to three, but the code in aot-compiler.c was not updated to match.

mono/mini/aot-compiler.c

index e0e23e29270f3b92c63223e041cd1faab2c9eab7..adce7d78aa4e277367fb68d4590df318c791dcf1 100644 (file)
@@ -3844,13 +3844,14 @@ add_wrappers (MonoAotCompile *acfg)
                csig->params [1] = &mono_defaults.exception_class->byval_arg;
                add_method (acfg, get_runtime_invoke_sig (csig));
 
-               /* Assembly runtime-invoke (string, bool) [DoAssemblyResolve] */
-               csig = mono_metadata_signature_alloc (mono_defaults.corlib, 2);
+               /* Assembly runtime-invoke (string, Assembly, bool) [DoAssemblyResolve] */
+               csig = mono_metadata_signature_alloc (mono_defaults.corlib, 3);
                csig->hasthis = 1;
                csig->ret = &(mono_class_load_from_name (
                                                                                        mono_defaults.corlib, "System.Reflection", "Assembly"))->byval_arg;
                csig->params [0] = &mono_defaults.string_class->byval_arg;
-               csig->params [1] = &mono_defaults.boolean_class->byval_arg;
+               csig->params [1] = &(mono_class_load_from_name (mono_defaults.corlib, "System.Reflection", "Assembly"))->byval_arg;
+               csig->params [2] = &mono_defaults.boolean_class->byval_arg;
                add_method (acfg, get_runtime_invoke_sig (csig));
 
                /* runtime-invoke used by finalizers */