From 35c6151c4040225f326b34cb8fc93767bf5017ac Mon Sep 17 00:00:00 2001 From: cedric Date: Tue, 20 Jul 2010 12:10:40 +0000 Subject: [PATCH] * evas: fix fribidi lock. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@50380 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/engines/common/evas_intl_utils.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/lib/engines/common/evas_intl_utils.c b/src/lib/engines/common/evas_intl_utils.c index a122d9b..fa74f52 100644 --- a/src/lib/engines/common/evas_intl_utils.c +++ b/src/lib/engines/common/evas_intl_utils.c @@ -11,10 +11,6 @@ #define UTF8_BYTES_PER_CHAR 4 -#ifdef BUILD_PTHREAD -static LK(fribidi_lock); -#endif - /* FIXME: fribidi_utf8_to_unicode should use char len and not byte len!*/ char * evas_intl_utf8_to_visual(const char *text, @@ -80,15 +76,15 @@ evas_intl_utf8_to_visual(const char *text, tmp_V_to_L_list = *position_V_to_L_list; } - LKL(fribidi_lock); + FBDLOCK(); if (!fribidi_log2vis(unicode_in, len, direction, unicode_out, tmp_L_to_V_list, tmp_V_to_L_list, tmp_level_list)) { - LKU(fribidi_lock); + FBDUNLOCK(); len = -2; goto error2; } - LKU(fribidi_lock); + FBDUNLOCK(); text_out = malloc(UTF8_BYTES_PER_CHAR * len + 1); if (!text_out) @@ -97,6 +93,7 @@ evas_intl_utf8_to_visual(const char *text, goto error2; } + FBDLOCK(); fribidi_unicode_to_utf8(unicode_out, len, text_out); FBDUNLOCK(); -- 2.7.4