gisi: switch to musl-safe character conversion
PATCH 1/1 gisi: switch to musl-safe character conversion
Support isimodem (gisi) use on musl libc systems by dropping the use of the iconv TRANSLIT extension when converting from UCS2 to UTF-8 [1]
[1] https://wiki.musl-libc.org/functional-differences-from-glibc.html#iconv
--- gisi/iter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
gisi/iter.c +2 -2
@@ -27,6 +27,7 @@#include <string.h> #include <glib.h> #include <arpa/inet.h> +#include <ell/ell.h> #include "iter.h"
@@ -257,8 +258,7 @@ gboolean g_isi_sb_iter_get_alpha_tag(const GIsiSubBlockIter *restrict iter,if (ucs2 + len > iter->end)return FALSE; - *utf8 =g_convert ((const char *) ucs2, len,"UTF-8//TRANSLIT" , -"UCS-2BE" ,NULL ,NULL ,NULL ); + *utf8 =l_utf8_from_ucs2be ((const char *) ucs2, len);return *utf8 !=NULL ; }
Signature · 1 line
2.42.0
Denis Kenzior
AppliedHi Sicelo,
Quoted 7 lines · Sicelo A. Mhlongo
Support isimodem (gisi) use on musl libc systems by dropping the use of the iconv TRANSLIT extension when converting from UCS2 to UTF-8 [1]
[1] https://wiki.musl-libc.org/functional-differences-from-glibc.html#iconv
--- gisi/iter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Applied, thanks.
Regards,
-Denis