From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5893 invoked from network); 28 Jul 1999 17:51:12 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 28 Jul 1999 17:51:12 -0000 Received: (qmail 7340 invoked by alias); 28 Jul 1999 17:45:49 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7311 Received: (qmail 7326 invoked from network); 28 Jul 1999 17:45:48 -0000 Message-ID: <19990728174717.22028.rocketmail@web1305.mail.yahoo.com> Date: Wed, 28 Jul 1999 10:47:17 -0700 (PDT) From: Felix Rosencrantz Subject: PATCH: Completion/matching control problem To: zsh-workers@sunsite.auc.dk MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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 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 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