From: raster Date: Thu, 15 Dec 2011 14:10:42 +0000 (+0000) Subject: see comments for info. a short workaround for now. X-Git-Tag: build/2012-07-04.173327~574 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=92461f77dd763684b5a8f8b0b1e6fa4246a122c9;p=profile%2Fivi%2Fecore.git see comments for info. a short workaround for now. git-svn-id: http://svn.enlightenment.org/svn/e/trunk/ecore@66258 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c index cc83b16..3430e97 100644 --- a/src/lib/ecore/ecore.c +++ b/src/lib/ecore/ecore.c @@ -217,14 +217,23 @@ shutdown_evil: EAPI int ecore_shutdown(void) { + Ecore_Pipe *p; /* * take a lock here because _ecore_event_shutdown() does callbacks */ _ecore_lock(); if (--_ecore_init_count != 0) goto unlock; - - ecore_pipe_del(_thread_call); + + /* this looks horrible - a hack for now, but something to note. as + * we delete the _thread_call pipe a thread COULD be doing + * ecore_pipe_write() or what not to it at the same time - we + * must ensure all possible users of this _thread_call are finished + * and exited before we delete it here */ + p = _thread_call; + _thread_call = NULL; + ecore_pipe_wait(p, 1, 0.1); + ecore_pipe_del(p); eina_lock_free(&_thread_safety); eina_condition_free(&_thread_cond); eina_lock_free(&_thread_mutex);