Evas textblock: Possible workaround for the infinite loop morlenxus is having.
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 29 May 2011 21:11:58 +0000 (21:11 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sun, 29 May 2011 21:11:58 +0000 (21:11 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@59791 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index bd015fa..3fbd717 100644 (file)
@@ -2842,6 +2842,13 @@ skip:
              script_len = tmp_cut;
           }
 
+        /* FIXME: This is a possible fix for an infinite loops that happens
+         * if script_len <= 0. Should find the source of the issue,
+         * i.e why (off - (str - tbase)) is ever < 0. I can't reproduce the
+         * issue so I can't really do anything about it. */
+        if (script_len <= 0)
+           break;
+
         script = evas_common_language_script_type_get(str, script_len);