Hi all,

after upgrading one of my boxes to OpenBSD 3.9, I couldn't log in with tcsh any more. It looks like malloc options 'AFGJP' trigger a core dump with tcsh.

I recompiled tcsh with debug symbols and ran gdb, which gives me the following output:
# gdb /usr/local/bin/tcsh tcsh.core
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-unknown-openbsd3.9"...
Core was generated by `tcsh'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/lib/libtermlib.so.10.0...done.
Loaded symbols for /usr/lib/libtermlib.so.10.0
Reading symbols from /usr/lib/libc.so.39.0...done.
Loaded symbols for /usr/lib/libc.so.39.0
Reading symbols from /usr/libexec/ld.so...done.
Loaded symbols for /usr/libexec/ld.so
#0  update_vars (vp=0x826f0c80) at sh.set.c:75
75              HISTSUB = *pn;
(gdb) bt full
#0  update_vars (vp=0x826f0c80) at sh.set.c:75
        pn = (Char *) 0x82b6bffc
#1  0x1c01d7c0 in doset (v=0x893b534c, c=0x83303600) at sh.set.c:309
        e = (Char **) 0x0
        p = (Char *) 0x826f0ca8
        vp = (Char *) 0x826f0c80
        op = 0
        vecp = (Char **) 0x82b6bffc
        hadsub = 0
        subscr = 1006668716
        flags = 2
        first_match = 0
        last_match = 0
        changed = -2106651480
#2  0x1c00e95d in func (t=0x83303600, bp=0x3c007850) at sh.func.c:152
        i = 2
#3 0x1c01be9e in execute (t=0x83303600, wanttty=11236, pipein=0x0, pipeout=0x0, do_glob=1) at sh.sem.c:650
        forked = 0
        bifunc = (struct biltins *) 0x3c007850
        pid = 0
        pv = {557, 557}
        csigmask = 0
        onosigchld = 0
        nosigchld = 0
#4 0x1c01c7df in execute (t=0x83303b40, wanttty=11236, pipein=0x0, pipeout=0x0, do_glob=1) at sh.sem.c:710
        forked = 0
        bifunc = (struct biltins *) 0x0
        pid = 0
        pv = {0, 0}
        csigmask = 0
        onosigchld = 0
        nosigchld = 0
#5  0x1c004ea9 in process (catch=0) at sh.c:2180
osetexit = {j = {469833313, 1, -809792948, -809792808, 1007006568, -809792840, 2, 0, 0, 0}}
        t = (struct command *) 0x83303760
#6  0x1c0117fb in doeval (v=0x82b6bffc, c=0x83303f80) at sh.func.c:2372
        oevalvec = (Char **) 0x0
        oevalp = (Char *) 0x0
        odidfds = 1
osetexit = {j = {469781503, 1, -809775860, -809775752, 1, 0, 2, 0, 0, 0}}
        my_reenter = 0
        savegv = (Char **) 0x0
        saveIN = 6
        saveOUT = 17
        saveDIAG = 18
        oSHIN = 6
        oSHOUT = 17
        oSHDIAG = 18
#7  0x1c00e95d in func (t=0x83303f80, bp=0x3c007680) at sh.func.c:152
        i = 1
#8 0x1c01be9e in execute (t=0x83303f80, wanttty=11236, pipein=0x0, pipeout=0x0, do_glob=1) at sh.sem.c:650
        forked = 0
        bifunc = (struct biltins *) 0x3c007680
        pid = 0
---Type <return> to continue, or q <return> to quit---q

Is it a bug in tcsh or did I misconfigure malloc options? (sorry, I don't have any experience in C debugging and actually don't know what I'm doing...)

regards,
Andreas

Reply via email to