From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21792 invoked from network); 3 Oct 1999 05:06:42 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 3 Oct 1999 05:06:42 -0000 Received: (qmail 14794 invoked by alias); 3 Oct 1999 05:06:32 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8123 Received: (qmail 14787 invoked from network); 3 Oct 1999 05:06:31 -0000 From: "Bart Schaefer" Message-Id: <991003050626.ZM30295@candle.brasslantern.com> Date: Sun, 3 Oct 1999 05:06:26 +0000 In-Reply-To: <19990926173658.A352@vmunix.com> Comments: In reply to Gabor "prompt bug?" (Sep 26, 5:36pm) References: <19990926173658.A352@vmunix.com> X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-workers@sunsite.auc.dk, Gabor Subject: PATCH: 3.1.6: Extra slash in $PWD (Re: prompt bug?) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Sep 26, 5:36pm, Gabor wrote: } Subject: prompt bug? } } I discovered this interesting anomoly in my prompt } } PS1='=== %(3/;%2/;%/) $ ' } === //tmp $ I'm still hoping to have a more detailed look at "cd" and friends, but this was quick'n'dirty. Line numbers may be off a tad. Index: Src/builtin.c =================================================================== @@ -963,7 +963,8 @@ buf = ztrdup(dest); else { dlen = strlen(pwd); - + if (pwd[dlen-1] == '/') + --dlen; buf = zalloc(dlen + strlen(dest) + 2); strcpy(buf, pwd); buf[dlen] = '/'; -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com