Re: trouble with asprintf

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Udo Richter wrote:
> Wolfgang Rohdewald wrote:
> > since asprintf leads to segfaults if feeded with incorrect UTF-8 characters,
> > I wanted to write a wrapper function which would then check the return value
> > of asprintf. 
> 
> I never understood what the problem is with utf8 and asprintf, since 
> utf8 is mostly ASCIIZ backwards compatible, and asprintf probably 
> doesn't even know the difference between utf8 and ascii. What special 
> handling does asprintf with utf8? Is there some example that causes the 
> trouble?

asprintf needs to check for multibyte characters to not cut them in
the middle and produce invalid output.

cu
Ludwig

-- 
 (o_   Ludwig Nussel
 //\   
 V_/_  http://www.suse.de/
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nuernberg)





_______________________________________________
vdr mailing list
vdr@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr

[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux