Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-05 Thread Florian Weimer
* Sven Luther: As said, i see this on both an x86 box and my powerbook, but the complete code is more involved, having a pselect, as well as a SIGALRM handler, which both trigger the localtime_r, as well as a postgresql access and files access. localtime_r is not async-signal-safe, so this

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-05 Thread Florian Weimer
* Sven Luther: On Thu, Apr 05, 2007 at 08:46:08AM +0200, Florian Weimer wrote: * Sven Luther: As said, i see this on both an x86 box and my powerbook, but the complete code is more involved, having a pselect, as well as a SIGALRM handler, which both trigger the localtime_r, as

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-05 Thread Sven Luther
On Thu, Apr 05, 2007 at 08:46:08AM +0200, Florian Weimer wrote: * Sven Luther: As said, i see this on both an x86 box and my powerbook, but the complete code is more involved, having a pselect, as well as a SIGALRM handler, which both trigger the localtime_r, as well as a postgresql

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-05 Thread Sven Luther
On Thu, Apr 05, 2007 at 01:35:22PM +0200, Florian Weimer wrote: * Sven Luther: On Thu, Apr 05, 2007 at 08:46:08AM +0200, Florian Weimer wrote: * Sven Luther: As said, i see this on both an x86 box and my powerbook, but the complete code is more involved, having a pselect, as

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-05 Thread Florian Weimer
* Sven Luther: Yes, i use localtime / getoftime / time from the signal handler, yes, i guess that is causing the problem i m seeing. Need to find another way to find the time from a handler. maybe using the timer_create thingy, but it is also undocumented. timer_gettime is async-signal-safe

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-04 Thread Sven Luther
Package: libc6 Version: 2.3.6.ds1-13 Severity: important I was writing a program using localtime, and i noticed some crashes every so often (a call every 50ms or so, a crash every 1-2 minutes), which yielded the following message : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1'

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-04 Thread Stephen Gran
This one time, at band camp, Sven Luther said: The code yielding to this was of the kind of : struct tm tm; time_t t; t = time(NULL); localtime (t, tm); This is in a fr_FR.utf8 locale, on a powerpc box. The same code on an x86 box just segfaults without error message. That

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-04 Thread Sven Luther
On Wed, Apr 04, 2007 at 07:50:02PM +0100, Stephen Gran wrote: This one time, at band camp, Sven Luther said: The code yielding to this was of the kind of : struct tm tm; time_t t; t = time(NULL); localtime (t, tm); This is in a fr_FR.utf8 locale, on a powerpc box.

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-04 Thread Stephen Gran
This one time, at band camp, Sven Luther said: And indeed, like i said, it worked fine 100s of times, and then died. Try : int main (void) { struct tm tm; time_t t; while (1) { t = time(NULL); localtime_r (t, tm); } exit(0); } [EMAIL PROTECTED]:~$ cat t.c #include

Bug#417815: libc6: localtime dies with : tzfile.c:544: __tzfile_compute: Assertion `num_types == 1' failed

2007-04-04 Thread Sven Luther
On Thu, Apr 05, 2007 at 12:00:01AM +0100, Stephen Gran wrote: This one time, at band camp, Sven Luther said: And indeed, like i said, it worked fine 100s of times, and then died. Try : int main (void) { struct tm tm; time_t t; while (1) { t = time(NULL); localtime_r