Merge pull request #5120 from lambdageek/bug-57744
authorAleksey Kliger (λgeek) <akliger@gmail.com>
Tue, 27 Jun 2017 14:44:30 +0000 (10:44 -0400)
committerGitHub <noreply@github.com>
Tue, 27 Jun 2017 14:44:30 +0000 (10:44 -0400)
[reflection] Convert correct MonoError to an exn in Assembly.GetTypes ()

1  2 
mono/metadata/icall.c

diff --combined mono/metadata/icall.c
index 9692845d19089e457199d61da221fa3df58f6cbc,48e0f67c56afaa9cea848a70cedb03f6452ab6b9..76ccc633aacb095aa61157cda783347c1df962ee
@@@ -5465,7 -5465,7 +5465,7 @@@ image_get_type (MonoDomain *domain, Mon
  
                MONO_HANDLE_ARRAY_SETREF (res, count, rt);
        } else {
-               MonoException *ex = mono_error_convert_to_exception (error);
+               MonoException *ex = mono_error_convert_to_exception (&klass_error);
                MONO_HANDLE_ARRAY_SETRAW (exceptions, count, ex);
        }
        HANDLE_FUNCTION_RETURN ();
@@@ -7866,7 -7866,7 +7866,7 @@@ ves_icall_System_Runtime_InteropService
  }
  
  ICALL_EXPORT MonoObject*
 -ves_icall_System_Runtime_InteropServices_WindowsRuntime_UnsafeNativeMethods_GetRestrictedErrorInfo()
 +ves_icall_System_Runtime_InteropServices_WindowsRuntime_UnsafeNativeMethods_GetRestrictedErrorInfo(void)
  {
        mono_set_pending_exception(mono_get_exception_not_implemented("System.Runtime.InteropServices.WindowsRuntime.UnsafeNativeMethods.GetRestrictedErrorInfo internal call is not implemented."));
        return NULL;