diff options
| author | Ignacio Etcheverry <ignalfonsore@gmail.com> | 2018-06-26 21:03:42 +0200 |
|---|---|---|
| committer | Ignacio Etcheverry <ignalfonsore@gmail.com> | 2018-07-04 03:08:29 +0200 |
| commit | 4739cb8c0003a7c35220ce43d8263df617c6fbe0 (patch) | |
| tree | 257bd9f9e4951c0b90db9220fc3eeb1bf45b5f65 /modules/mono/editor/monodevelop_instance.cpp | |
| parent | 68f7cf13c7326c077cc6ff8a6a267ae2610c4519 (diff) | |
| download | redot-engine-4739cb8c0003a7c35220ce43d8263df617c6fbe0.tar.gz | |
Mono: Pending exceptions and cleanup
Diffstat (limited to 'modules/mono/editor/monodevelop_instance.cpp')
| -rw-r--r-- | modules/mono/editor/monodevelop_instance.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/modules/mono/editor/monodevelop_instance.cpp b/modules/mono/editor/monodevelop_instance.cpp index 48a285561d..9f05711fd6 100644 --- a/modules/mono/editor/monodevelop_instance.cpp +++ b/modules/mono/editor/monodevelop_instance.cpp @@ -40,14 +40,14 @@ void MonoDevelopInstance::execute(const Vector<String> &p_files) { ERR_FAIL_NULL(execute_method); ERR_FAIL_COND(gc_handle.is_null()); - MonoObject *ex = NULL; + MonoException *exc = NULL; Variant files = p_files; const Variant *args[1] = { &files }; - execute_method->invoke(gc_handle->get_target(), args, &ex); + execute_method->invoke(gc_handle->get_target(), args, &exc); - if (ex) { - mono_print_unhandled_exception(ex); + if (exc) { + GDMonoUtils::debug_unhandled_exception(exc); ERR_FAIL(); } } @@ -68,14 +68,14 @@ MonoDevelopInstance::MonoDevelopInstance(const String &p_solution) { MonoObject *obj = mono_object_new(TOOLS_DOMAIN, klass->get_mono_ptr()); GDMonoMethod *ctor = klass->get_method(".ctor", 1); - MonoObject *ex = NULL; + MonoException *exc = NULL; Variant solution = p_solution; const Variant *args[1] = { &solution }; - ctor->invoke(obj, args, &ex); + ctor->invoke(obj, args, &exc); - if (ex) { - mono_print_unhandled_exception(ex); + if (exc) { + GDMonoUtils::debug_unhandled_exception(exc); ERR_FAIL(); } |
