Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh seg fault when TERM = linux
- X-seq: zsh-workers 26912
- From: Murilo Opsfelder Araújo <mopsfelder@xxxxxxxxx>
- To: Peter Stephenson <pws@xxxxxxx>
- Subject: Re: zsh seg fault when TERM = linux
- Date: Thu, 30 Apr 2009 18:22:26 -0300
- Cc: zsh-workers@xxxxxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :from:date:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=aVMyZvSD7i6/uPwUQLy4+34aQtvoqRidxCs8G1aMQ0c=; b=eHSEY1tqHTk/fBl1rvMD+73RpmGXm8U0ZXYs+m60zzwBmTf0btPREGEkzY3CnVGMp8 /D9LC/xcfjW3DHKrcPDpzHwZ6tbLjbCfjC+tAnuzWXwzmyzYjsWNsdSluU6T1BWf2l09 aaNHx5k70IBvV1thM8U+0olhe+PXQycDRNzUg=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=BuKM2ubYFAfxn3bp3Xnl34gvW+uQrMoDysp4B7NfJpE5FI9fgDiajlZb6f8lpz8/Hm ZzhfVD6Tajvs59PWcSvzmsMYg8xFt8qCbDEgTJFOFd4PfElFYudM3oEm7jVlKm965CgH gaB0+lPsMSYTx/LI238d0mlZXm+dmc2f3l4w4=
- In-reply-to: <200904301354.n3UDsoNM021549@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <e17dc37a0904300535q4ff7b681w76a2d63f7b8a1146@xxxxxxxxxxxxxx> <200904301354.n3UDsoNM021549@xxxxxxxxxxxxxx>
On Thu, Apr 30, 2009 at 10:54 AM, Peter Stephenson <pws@xxxxxxx> wrote:
> =?ISO-8859-1?Q?Murilo_Opsfelder_Ara=FAjo?= wrote:
>> TERM env var on client side is set to 'linux':
>>
>> server$ gdb zsh
>> (gdb) bt
>> #0 0x283784bd in strlen () from /lib/libc.so.7
>> #1 0x282f600e in cgetset () from /lib/libc.so.7
>> #2 0x282f64f2 in cgetent () from /lib/libc.so.7
>> #3 0x2824940e in _nc_read_termcap_entry () from /lib/libncursesw.so.7
>> #4 0x2826accf in _nc_read_entry () from /lib/libncursesw.so.7
>> #5 0x28268d47 in _nc_setupterm () from /lib/libncursesw.so.7
>> #6 0x2823d928 in tgetent () from /lib/libncursesw.so.7
>> #7 0x0807bd29 in init_term ()
>> #8 0x0809593b in setstrvalue ()
>> #9 0x08099ba7 in assignsparam ()
>> #10 0x0809ab3e in createparamtable ()
>> #11 0x0807b9df in setupvals ()
>> #12 0x0807d6ce in zsh_main ()
>> #13 0x08052e32 in main ()
>> (gdb)
>>
>> Does gdb seem to be OK?
>
> Yes, the backtrace makes sense. However, the crash is down inside the
> library code, where zsh calls tgetent(). The shell simply passes down
> the terminal name, i.e. the string "linux", and maybe a buffer. It's
> going through calls to ncursesw and libc, which is correct.
>
> Do you have the configuration for this version of zsh? Can you see if
> the option TGETENT_ACCEPTS_NULL is #define'd in config.h? It should be
> under Linux, but if it wasn't it might be that the 2048-byte buffer was
> too short. If the option is set, it's hard to see how the shell could
> be causing this. Indeed, I see in the manual page for tgetent that the
> buffer pointer is ignored, although it wasn't specially about ncursesw.
>
> Can you post the output of "infocmp -C linux" on the system where it's
> crashing?
>
> Thanks.
>
> --
> Peter Stephenson <pws@xxxxxxx> Software Engineer
> CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
> Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
>
The server side /etc/zshrc:
http://pastebin.com/m65da7ea1
How can I see in zsh of server side if TGETENT_ACCEPTS_NULL is set?
On the server side (where zsh crashes) there is no command 'infocmp'.
The server is running FreeBSD. On the client side, here is the output
of 'infocmp -C linux':
http://pastebin.com/m352212c1
Thanks in advance.
--
Murilo Opsfelder Araujo
mopsfelder@xxxxxxxxx
{murilo,panda}@bsd.com.br
BSD will never die.
"Tempo difícil esse em que estamos, em que é mais fácil quebrar um
átomo do que um preconceito." - Albert Einstein
Messages sorted by:
Reverse Date,
Date,
Thread,
Author