From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20591 invoked from network); 20 Feb 2002 17:01:12 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 20 Feb 2002 17:01:12 -0000 Received: (qmail 25323 invoked by alias); 20 Feb 2002 17:01:00 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 16677 Received: (qmail 25289 invoked from network); 20 Feb 2002 17:00:58 -0000 To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: Bug in history changes Date: Wed, 20 Feb 2002 17:00:30 +0000 Message-ID: <5921.1014224430@csr.com> From: Peter Stephenson The latest version of the history code is causing zcalc to crash. zcalc now tries to use its own separate history file; it's a bit hacky because the history interface isn't intended for use like this. The instruction that triggers it is setting HISTSIZE to 0. (gdb) bt #0 0x3b200 in putoldhistentryontop (keep_going=-3664) at ../../Src/hist.c:937 #1 0x3ce44 in resizehistents () at ../../Src/hist.c:1776 #2 0x5d9c4 in histsizesetfn (pm=0x9b330, v=4294967296) at ../../Src/params.c:2915 #3 0x5a728 in setstrvalue (v=0xffbee7f0, val=0xef3a8 "0") at ../../Src/params.c:1637 #4 0x5b740 in assignsparam (s=0xbbfe0 "", val=0xef3a8 "0", augment=0) at ../../Src/params.c:1991 #5 0x1ef64 in typeset_single (cname=0xbbfd0 "local", pname=0xbbfd8 "HISTSIZE", pm=0x9b330, func=0, on=131072, off=0, roff=0, value=0xbbfe1 "0", altpm=0x0) at ../../Src/builtin.c:1868 #6 0x203f0 in bin_typeset (name=0xbbfd0 "local", argv=0xffbee9bc, ops=0xffbee9d0 "", func=0) at ../../Src/builtin.c:2127 #7 0x1aa04 in execbuiltin (args=0xbbfb0, bn=0x99c50) at ../../Src/builtin.c:377 #8 0x2df58 in execcmd (state=0xffbeed80, input=0, output=0, how=2, last1=2) at ../../Src/exec.c:2306 #9 0x2b2b4 in execpline2 (state=0xffbeed80, pcode=192, how=2, input=0, output=0, last1=0) at ../../Src/exec.c:1201 #10 0x2a808 in execpline (state=0xffbeed80, slcode=128, how=2, last1=0) at ../../Src/exec.c:991 #11 0x2a2a8 in execlist (state=0xffbeed80, dont_change_job=1, exiting=0) at ../../Src/exec.c:826 #12 0x29fb0 in execode (p=0xf37c8, dont_change_job=1, exiting=0) at ../../Src/exec.c:729 #13 0x2ffac in execautofn (state=0xd5de8, do_exec=0) at ../../Src/exec.c:3245 #14 0x2dd0c in execcmd (state=0xffbef130, input=0, output=0, how=18, last1=2) at ../../Src/exec.c:2253 #15 0x2b2b4 in execpline2 (state=0xffbef130, pcode=0, how=18, input=0, output=0, last1=0) at ../../Src/exec.c:1201 #16 0x2a808 in execpline (state=0xffbef130, slcode=96, how=18, last1=0) at ../../Src/exec.c:991 #17 0x2a2a8 in execlist (state=0xffbef130, dont_change_job=1, exiting=0) at ../../Src/exec.c:826 #18 0x29fb0 in execode (p=0xf32e8, dont_change_job=1, exiting=0) at ../../Src/exec.c:729 #19 0x30630 in runshfunc (prog=0xf32e8, wrap=0x0, name=0xbbdf8 "zcalc") at ../../Src/exec.c:3492 #20 0x303f4 in doshfunc (name=0xca520 "zcalc", prog=0xf32e8, doshargs=0xef3d0, flags=0, noreturnval=0) at ../../Src/exec.c:3407 #21 0x2ff38 in execshfunc (shf=0xd5de8, args=0xbbdd0) at ../../Src/exec.c:3217 #22 0x2decc in execcmd (state=0xffbef670, input=0, output=0, how=18, last1=2) at ../../Src/exec.c:2295 #23 0x2b2b4 in execpline2 (state=0xffbef670, pcode=4, how=18, input=0, output=0, last1=0) at ../../Src/exec.c:1201 #24 0x2a808 in execpline (state=0xffbef670, slcode=96, how=18, last1=0) at ../../Src/exec.c:991 #25 0x2a2a8 in execlist (state=0xffbef670, dont_change_job=0, exiting=0) at ../../Src/exec.c:826 #26 0x29fb0 in execode (p=0xbbd88, dont_change_job=0, exiting=0) at ../../Src/exec.c:729 #27 0x3e3a8 in loop (toplevel=1, justonce=0) at ../../Src/init.c:165 #28 0x40ad0 in zsh_main (argc=1, argv=0x1) at ../../Src/init.c:1214 #29 0x1a220 in main (argc=1, argv=0xffbef844) at ../../Src/main.c:37 if (he != hist_ring->down) { => he->up->down = he->down; he->down->up = he->up; he->up = hist_ring; he->down = hist_ring->down; hist_ring->down = he->down->up = he; } (gdb) p he->up $1 = 0xffffffff -- Peter Stephenson Software Engineer CSR Ltd., Science Park, Milton Road, Cambridge, CB4 0WH, UK Tel: +44 (0)1223 392070 ********************************************************************** The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. **********************************************************************