Yeah, this is because we use the character conversion functions from libxml. I have a different version based on iconv that behaves more sane.
Problem: iconv is not guaranteed to be portable (e.g. to Win). Regards Jörg -----Original Message----- From: Bruno David Rodrigues To: Kannel-devel (E-mail) Sent: 3/5/02 7:27 PM Subject: [RFI] octstr_recode I'm trying to use the octstr_recode function to convert a MO message from UCS2 to ISO-8859-1 or UTF-8 I was thinking in trying to recode to ISO-8859-1 if possible, otherwise convert to UTF-8 and set coding acordly. I thought that if the text couldn't be translated to ISO-8859, octstr_recode (octstr_imm("iso-8859-1"), octstr_imm("UTF-16BE"), text)) would return false and I could switch to octstr_recode (octstr_imm("utf-8"), octstr_imm("UTF-16BE"), text) but the first recode converts my %06%4A to a ي and returns ok. 2002-03-05 18:04:51 [6] INFO: DAVI:Received message with coding 3 2002-03-05 18:04:51 [6] INFO: DAVI:Received unicode message -J-064A- 2002-03-05 18:04:51 [6] INFO: DAVI: recode to iso8859-1 -ي-2623313631303B- 2002-03-05 18:04:51 [6] INFO: Starting to service <ي> from <my-number> to <short-number> 2002-03-05 18:04:51 [6] DEBUG: formatted text answer: <Go away> 2002-03-05 18:04:51 [6] DEBUG: message length 7, sending 1 messages May I search for &#xxxx; in utf16-be to iso8859-1 and reject it, switching then to utf8 ??