diff options
Diffstat (limited to '')
-rw-r--r-- | libraries/ecore/src/lib/ecore/ecore_glib.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/libraries/ecore/src/lib/ecore/ecore_glib.c b/libraries/ecore/src/lib/ecore/ecore_glib.c index 6ddcd36..7cea1c9 100644 --- a/libraries/ecore/src/lib/ecore/ecore_glib.c +++ b/libraries/ecore/src/lib/ecore/ecore_glib.c | |||
@@ -2,6 +2,7 @@ | |||
2 | # include <config.h> | 2 | # include <config.h> |
3 | #endif | 3 | #endif |
4 | 4 | ||
5 | #include <stdlib.h> | ||
5 | #include <stdio.h> | 6 | #include <stdio.h> |
6 | 7 | ||
7 | #include "Ecore.h" | 8 | #include "Ecore.h" |
@@ -189,7 +190,9 @@ _ecore_glib_select(int ecore_fds, | |||
189 | int ret; | 190 | int ret; |
190 | 191 | ||
191 | if (g_main_context_acquire(ctx)) | 192 | if (g_main_context_acquire(ctx)) |
192 | g_mutex_lock(mutex); | 193 | { |
194 | if (mutex) g_mutex_lock(mutex); | ||
195 | } | ||
193 | else | 196 | else |
194 | { | 197 | { |
195 | if (!_ecore_glib_cond) | 198 | if (!_ecore_glib_cond) |
@@ -202,8 +205,9 @@ _ecore_glib_select(int ecore_fds, | |||
202 | ret = _ecore_glib_select__locked | 205 | ret = _ecore_glib_select__locked |
203 | (ctx, ecore_fds, rfds, wfds, efds, ecore_timeout); | 206 | (ctx, ecore_fds, rfds, wfds, efds, ecore_timeout); |
204 | 207 | ||
205 | g_mutex_unlock(mutex); | 208 | if (mutex) g_mutex_unlock(mutex); |
206 | g_main_context_release(ctx); | 209 | g_main_context_release(ctx); |
210 | g_static_mutex_free(&lock); | ||
207 | 211 | ||
208 | return ret; | 212 | return ret; |
209 | } | 213 | } |