On Sat, Jul 26, 2008 at 09:54:02PM +0200, Carsten Hey wrote:
> On Sat, Jul 26, 2008 at 03:02:56PM +0200, Martijn van Oosterhout wrote:
> > On Sat, Jul 26, 2008 at 12:59:57PM +0200, Carsten Hey wrote:
> > > On Sat, Jul 26, 2008 at 12:34:23PM +0200, Christian Kuka wrote:
> > > > 20080724 Neue DAN-Träger im VTB: Dieter Bölts und Mara Meiners
> > > > bestehen die Prüfung zum 1. DAN im Traditionellen Taekwon-Do. Der VTB
> > > > gratuliert ganz herzlich!!!
> > >
> > > this is UTF8 parsed as ISO_8859-15. Since a fix for this bug probably
> > > won't hit Debian lenny (the freeze will happen in the next 72 hours)
> > > I suggest piping this lines through iconv before putting them into a pal
> > > calendar file as workaround:
> >
> > I'm not understanding what the problem is. If I put UTF-8 in my pal
> > files it works fine. I also don't understand how it could segfault.
> > Cutting and pasting the line from my email doesn't trigger anything.
> > Can either of you send me a file as an attachment that triggers it?
>
> I reproduced the bug using:
>
>     LC_ALL=C pal --mail
>
> The following command does *NOT* segfault:
>
>     LC_ALL=de_DE.UTF-8 pal --mail
>
> The calendar file is attached.

In output.c, line 44 g_locale_from_utf8 is used to convert the string
that should be printed to the systems locale. This function returns
either the converted string or NULL in case of an error. We pass the
return value without prior checking whether it is NULL to fputs (in case
of non-curses output).

Just for the record, the backtrace:

(gdb) bt
#0  0xb7e07463 in strlen () from /lib/tls/i686/cmov/libc.so.6
#1  0xb7df1c28 in fputs () from /lib/tls/i686/cmov/libc.so.6
#2  0x0804dc55 in pal_output_handler (instr=0x8064ce0 "DAN-TrÃ\203¤ger")
at output.c:47
#3  0xb7f738b8 in g_print () from /usr/lib/libglib-2.0.so.0
#4  0x0804e7d8 in pal_output_wrap (string=0x8062a00 "Neue
DAN-TrÃ\203¤ger im VTB: Dieter BÃ\203¶lts und Mara Meiners",
chars_used=7, indent=2) at output.c:430
#5  0x0804ead0 in pal_output_event (event=0x8062148, date=0x8065550,
selected=0) at output.c:527
#6  0x0804ed63 in pal_output_date (date=0x8065550, show_empty_days=0,
selected_event=-1) at output.c:595
#7  0x0804abbd in view_range (starting_date=0x8065550, window=8) at
main.c:58
#8  0x0804c0bd in view_details () at main.c:404
#9  0x0804d5f1 in main (argc=2, argv=0xbff837b4) at main.c:813


Regards,
Carsten



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to