diff options
author | Not Zed <NotZed@HelixCode.com> | 2000-12-24 08:58:02 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2000-12-24 08:58:02 +0800 |
commit | 5674966eeb7eecfa109ad419f1c997dba69ff0af (patch) | |
tree | a439ac65139c39f3f551573b1c9f14a8e56b1c82 /libibex/ibex_internal.h | |
parent | d5b5b5f0979f0819561fbec36a417a6dcfc3d4d5 (diff) | |
download | gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar.gz gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar.bz2 gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar.lz gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar.xz gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.tar.zst gsoc2013-evolution-5674966eeb7eecfa109ad419f1c997dba69ff0af.zip |
Merge from camel-mt-branch.
2000-12-24 Not Zed <NotZed@HelixCode.com>
* Merge from camel-mt-branch.
svn path=/trunk/; revision=7152
Diffstat (limited to 'libibex/ibex_internal.h')
-rw-r--r-- | libibex/ibex_internal.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/libibex/ibex_internal.h b/libibex/ibex_internal.h index 0eb4b625ce..f2212799c6 100644 --- a/libibex/ibex_internal.h +++ b/libibex/ibex_internal.h @@ -18,6 +18,8 @@ * Boston, MA 02111-1307, USA. */ +#include "config.h" + #include <glib.h> #include "ibex.h" @@ -29,4 +31,21 @@ struct ibex { struct _memcache *blocks; struct _IBEXWord *words; int predone; + + /* sigh i hate glib's mutex stuff too */ +#ifdef ENABLE_THREADS + GMutex *lock; +#endif + }; + +#ifdef ENABLE_THREADS +/*#define IBEX_LOCK(ib) (printf(__FILE__ "%d: %s: locking ibex\n", __LINE__, __FUNCTION__), g_mutex_lock(ib->lock)) + #define IBEX_UNLOCK(ib) (printf(__FILE__ "%d: %s: unlocking ibex\n", __LINE__, __FUNCTION__), g_mutex_unlock(ib->lock))*/ +#define IBEX_LOCK(ib) (g_mutex_lock(ib->lock)) +#define IBEX_UNLOCK(ib) (g_mutex_unlock(ib->lock)) +#else +#define IBEX_LOCK(ib) +#define IBEX_UNLOCK(ib) +#endif + |