From: Robert Jordan Date: Fri, 26 Feb 2010 17:59:22 +0000 (-0000) Subject: 2010-02-26 Robert Jordan X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=commitdiff_plain;h=c222f10f442850a6559cc89381d58b9c9b796220;p=mono.git 2010-02-26 Robert Jordan * tasklets.c (continuation_store): Return from an error condition immediately. svn path=/trunk/mono/; revision=152562 --- diff --git a/mono/mini/ChangeLog b/mono/mini/ChangeLog index 7f956248d90..1bb0b4c6ce7 100755 --- a/mono/mini/ChangeLog +++ b/mono/mini/ChangeLog @@ -1,3 +1,8 @@ +2010-02-26 Robert Jordan + + * tasklets.c (continuation_store): Return from an error condition + immediately. + 2010-02-26 Martin Baulig * debug-debugger.c (MonoDebuggerInfo): Added `abort_runtime_invoke'. diff --git a/mono/mini/tasklets.c b/mono/mini/tasklets.c index 22dd281000c..73d71fe074a 100644 --- a/mono/mini/tasklets.c +++ b/mono/mini/tasklets.c @@ -85,10 +85,14 @@ continuation_store (MonoContinuation *cont, int state, MonoException **e) MonoLMF *lmf = mono_get_lmf (); gsize num_bytes; - if (!cont->domain) + if (!cont->domain) { *e = mono_get_exception_argument ("cont", "Continuation not initialized"); - if (cont->domain != mono_domain_get () || cont->thread_id != GetCurrentThreadId ()) + return 0; + } + if (cont->domain != mono_domain_get () || cont->thread_id != GetCurrentThreadId ()) { *e = mono_get_exception_argument ("cont", "Continuation from another thread or domain"); + return 0; + } cont->lmf = lmf; cont->return_ip = __builtin_return_address (0);