kuuko pushed a commit to branch master.

commit 2f6edccf6e8607b5b9b2395f0a629cd9f9672d36
Author: Kai Huuhko <[email protected]>
Date:   Mon Apr 1 18:24:45 2013 +0000

    Eo: remove _c?fruni from list conv funcs.
---
 efl/eo/efl.eo.pyx | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/efl/eo/efl.eo.pyx b/efl/eo/efl.eo.pyx
index 3cab62a..50a4d5b 100644
--- a/efl/eo/efl.eo.pyx
+++ b/efl/eo/efl.eo.pyx
@@ -165,7 +165,8 @@ cdef const_char ** 
convert_python_list_strings_to_array_of_strings(list strings)
         raise MemoryError()
 
     for i in range(arr_len):
-        array[i] = <const_char *>strdup(_cfruni(strings[i]))
+        if isinstance(strings[i], unicode): s = strings[i].encode("UTF-8")
+        array[i] = <const_char *>strdup(s)
 
     return array
 
@@ -185,7 +186,8 @@ cdef list 
convert_eina_list_strings_to_python_list(const_Eina_List *lst):
 cdef Eina_List *convert_python_list_strings_to_eina_list(strings):
     cdef Eina_List *lst = NULL
     for s in strings:
-        lst = eina_list_append(lst, strdup(_cfruni(s)))
+        if isinstance(s, unicode): s = s.encode("UTF-8")
+        lst = eina_list_append(lst, strdup(s))
     return lst
 
 

-- 

------------------------------------------------------------------------------
Own the Future-Intel(R) Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest. Compete 
for recognition, cash, and the chance to get your game on Steam. 
$5K grand prize plus 10 genre and skill prizes. Submit your demo 
by 6/6/13. http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2

Reply via email to