From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by melb.werple.net.au (8.7.5/8.7.3) with ESMTP id NAA28535 for ; Sun, 12 May 1996 13:23:36 +1000 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id XAA04464; Sat, 11 May 1996 23:04:24 -0400 (EDT) Resent-Date: Sat, 11 May 1996 23:04:24 -0400 (EDT) From: Zoltan Hidvegi Message-Id: <199605120302.FAA05347@hzoli.ppp.cs.elte.hu> Subject: history-beginning-search fixes To: zsh-workers@math.gatech.edu (Zsh hacking and development) Date: Sun, 12 May 1996 05:02:20 +0200 (MET DST) Reply-To: hzoli@unicorn.sch.bme.hu X-Mailer: ELM [version 2.4ME+ PL11 (25)] MIME-Version: 1.0 Content-Type: application/pgp; format=text; x-action=sign Content-Transfer-Encoding: 7bit Resent-Message-ID: <"hiMZ61.0.d51.tKLbn"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/1054 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu -----BEGIN PGP SIGNED MESSAGE----- history-beginning-search-* stopped working after Zefram latest patch if the cursor was at the end of the line. Here is the fix. Zoltan *** Src/zle_hist.c 1996/05/12 01:46:12 2.8 --- Src/zle_hist.c 1996/05/12 02:27:59 *************** *** 1078,1085 **** histline = ohistline; return; } ! if (strlen((char *)s) > cs ! && !memcmp(s, (char *)line, cs) && memcmp(s, (char *)line, ll)) break; } --- 1078,1086 ---- histline = ohistline; return; } ! if (strlen((char *)s) > cs && ! !memcmp(s, (char *)line, cs) && ! (strlen((char *)s) > ll || memcmp(s, (char *)line, ll))) break; } *************** *** 1109,1116 **** histline = ohistline; return; } ! if (strlen((char *)s) > cs ! && !memcmp(s, (char *)line, cs) && memcmp(s, (char *)line, ll)) break; } --- 1110,1118 ---- histline = ohistline; return; } ! if ((histline == curhist || strlen((char *)s) > cs) && ! !memcmp(s, (char *)line, cs) && ! (strlen((char *)s) > ll || memcmp(s, (char *)line, ll))) break; } -----BEGIN PGP SIGNATURE----- Version: 2.6.3i Charset: noconv iQCVAwUBMZVUrQupSCiLN749AQEZ2wP9HffAr+fJP75w7oFaXO4fOKSxdSYddhvl uqW6rxF2KlM85mhhR3mnbenheKOO0WyNni1ZUvUJt9fofXMSxOf4cPtW2WZXKKTI gA5G2vXHQqDGdMuHKiEs1PmLmS6kmcweIYc4o8ytzTnfV8jqY7d9W/lQBZ7mLGZA uoWq7mIVTWE= =KJaY -----END PGP SIGNATURE-----