> From: Nahum Nir [[email protected]]
> 
> I'm implementing a SIP stack and having some problems with non ascii display
> name. The problem is that it is stored as short* and it needs to be
> converted to char*.

All SIP messages are sequences of Unicode characters, and the
characters are encoded using UTF-8.  See the first part of section 7.
The footnote there points you to RFC 2279, which gives the details of
UTF-8.

Your C library probably has routines to convert 2-byte character
representations (called UCS-2, and related to UTF-16) to/from UTF-8
(possibly after turning short* (UCS-2) into int* (UCS-4)).  E.g., my
"man -k UCS" command reveals:

FcUtf8ToUcs4         (3)  - convert UTF-8 to UCS4
stringprep_ucs4_to_utf8 (3)  - convert UCS-4 string to UTF-8

Dale

_______________________________________________
Sip-implementors mailing list
[email protected]
https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors

Reply via email to