From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6638 invoked from network); 8 Oct 2001 15:15:45 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 8 Oct 2001 15:15:45 -0000 Received: (qmail 17702 invoked by alias); 8 Oct 2001 15:15:40 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 15980 Received: (qmail 17689 invoked from network); 8 Oct 2001 15:15:39 -0000 To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: PATCH: bug in zcalc displaying bases (again) Date: Mon, 08 Oct 2001 16:14:54 +0100 Message-ID: <15265.1002554094@csr.com> From: Peter Stephenson Index: Functions/Misc/zcalc =================================================================== RCS file: /cvsroot/zsh/zsh/Functions/Misc/zcalc,v retrieving revision 1.3 diff -u -u -r1.3 zcalc --- zcalc 2001/08/16 16:42:21 1.3 +++ zcalc 2001/10/08 15:12:40 @@ -141,7 +141,11 @@ eval "latest=\$(( $line ))" argv[num++]=$latest psvar[1]=$num - print -- $(( $base $latest )) + if [[ -z $base ]]; then + print -- $latest + else + print -- $(( $base $latest )) + fi fi line= done -- 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. **********************************************************************