>>>> Jan Vroonhof writes:
Jan> Didier Verna <didier(a)xemacs.org> writes:
> didier(p2)% runsocks ./src/xemacs
14:08 02/26/00
> Fatal error: assertion failed, file /usr/local/src/XEmacs-21.2/src/signal.c, line
340, async_timer_suppress_count > 0
> zsh: segmentation fault (core dumped) runsocks ./src/xemacs
Jan> This is going to get ugly. XEmacs cannot handle library code
Jan> playing with timers. Any such code must be wrapped in
Jan> stop/start_async_timeouts (void) which unfortunately is also only available
Jan> as part of stop/start_interrupts.
Jan> A similar problem occurs with modern libesd.so's.. I have a patch for
Jan> that. However it seems that your socks library calls the fairly
Jan> innocent getlogin and that uses a timeout in glibc(). Apparently on
Jan> Linux the timers are fair game for libraries. In addition most of them
Jan> seem to be using alarm which has much lower resolution than the itimer
Jan> stuff.
Jan> We need a better solution for this. Andreas any ideas..?
Not directly. For now I just checked what we're doing in glibc.
> #10 0x8094ee4 in assert_failed (
> file=0x8299500 "/usr/local/src/XEmacs-21.2/src/signal.c", line=340,
> expr=0x82994e0 "async_timer_suppress_count > 0")
> at /usr/local/src/XEmacs-21.2/src/emacs.c:2770
> #11 0x81bde9d in alarm (howlong=0)
> at /usr/local/src/XEmacs-21.2/src/signal.c:340
> #12 0x4055045d in getutline_r () from /lib/libc.so.6
> #14 0x40509b5d in getlogin () from /lib/libc.so.6
> #15 0x400183c1 in lsEffUser () from /usr/local/lib/libsocks5_sh.so
> #18 0x4002262f in connect () from /usr/local/lib/libsocks5_sh.so
> #26 0x4051664b in getaddrinfo () from /lib/libc.so.6
> #27 0x81d386d in init_system_name ()
> at /usr/local/src/XEmacs-21.2/src/sysdep.c:2361
The problem seems to be sysdeps/generic/utmp_file.c. We try to lock
the utmp file and save/restore the alarm values (we don't mess around
with the values - but if XEmacs overwrites alarm...). That's AFAIK
(besides sleep) the only place where glibc uses alarm.
Jan> That means that with socks every call to the networking stuff can call
Jan> alarm(). Some more general solution must be found.
Jan> Jan
Jan> P.S. In the mean time play around with your nsswitch.conf to disable
Jan> to the setting that is triggering the alarm call.
I don't think that this is might help here.
Andreas
--
Andreas Jaeger
SuSE Labs aj(a)suse.de
private aj(a)arthur.rhein-neckar.de