zsh-workers
 help / color / mirror / code / Atom feed
From: Felix Rosencrantz <f_rosencrantz@yahoo.com>
To: zsh-workers@sunsite.auc.dk
Subject: PATCH: Completion/matching control problem
Date: Wed, 28 Jul 1999 10:47:17 -0700 (PDT)	[thread overview]
Message-ID: <19990728174717.22028.rocketmail@web1305.mail.yahoo.com> (raw)

Here's a problem with matching control that I encountered.  I've been
meaning to send this patch in for some time.  If I understood the code
better, I think I provide a cleaner test case.  

	mkdir bug
	cd bug
	touch Abc-Def-Ghij.txt
	touch Abc-def.ghi.jkl_mno.pqr.txt
	touch Abc_def_ghi_jkl_mno_pqr.txt
	compctl -M 'm:{a-z}={A-Z} r:|[.,_-]=*'
	ls a-a<TAB>

I sometimes see either a hang or a core dump.

The problem seems to occur when match_str is called with test=1 and abort_match
is called, the globals matchparts&matchsubs end up pointing to free'd clines,
which causes problems for code that attempts to append clines to the list.

I another problem is if you type:
	ls a<TAB>
you get:
	ls Abcdefghi
which doesn't seem correct, but I figure someone who understands the code might
be able to fix this one.

--- os/Zle/zle_tricky.c		Sun Jul 25 18:38:50 1999
+++ Src/Zle/zle_tricky.c	Mon Jul 26 22:44:26 1999
@@ -2121,6 +2121,7 @@
 {
     free_cline(matchparts);
     free_cline(matchsubs);
+    matchparts = matchsubs = NULL;
 }
 
 /* This adds a new string in the static char buffer. The arguments are


_____________________________________________________________
Do You Yahoo!?
Free instant messaging and more at http://messenger.yahoo.com


             reply	other threads:[~1999-07-28 17:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-07-28 17:47 Felix Rosencrantz [this message]
1999-07-29  8:03 ` Peter Stephenson
1999-08-02 11:28 Sven Wischnowsky
1999-08-02 12:36 Sven Wischnowsky
1999-08-02 12:50 Sven Wischnowsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=19990728174717.22028.rocketmail@web1305.mail.yahoo.com \
    --to=f_rosencrantz@yahoo.com \
    --cc=zsh-workers@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).