Re: mutt/2402: damaged regexps in folder-hooks
The following reply was made to PR mutt/2402; it has been noted by GNATS.
From: Thomas Roessler <roessler@xxxxxxxxxxxxxxxxxx>
To: bug-any@xxxxxxxxxxxxx
Cc:
Subject: Re: mutt/2402: damaged regexps in folder-hooks
Date: Thu, 3 Aug 2006 12:40:16 +0200
Eek. The obvious solution would be another level of \
escaping, but I don't like that thought at all. I guess I'd
rather throw out the folder expansion and just stick to regular
expressions.
--
Thomas Roessler <roessler@xxxxxxxxxxxxxxxxxx>
On 2006-08-03 12:35:02 +0200, Rocco Rutte wrote:
> From: Rocco Rutte <pdmef@xxxxxxx>
> To: Mutt Developers <mutt-dev@xxxxxxxx>
> Date: Thu, 03 Aug 2006 12:35:02 +0200
> Subject: Re: mutt/2402: damaged regexps in folder-hooks
> Reply-To: bug-any@xxxxxxxxxxxxx
> X-Spam-Level:
>
> The following reply was made to PR mutt/2402; it has been noted by GNATS.
>
> From: Rocco Rutte <pdmef@xxxxxxx>
> To: bug-any@xxxxxxxxxxxxx
> Cc:
> Subject: Re: mutt/2402: damaged regexps in folder-hooks
> Date: Thu, 3 Aug 2006 10:29:40 +0000
>
> Hi,
>
> * Alain Bench [06-08-03 07:31:38 +0200] wrote:
>
> > In Mutt 1.5.10 and more, the regexp in folder-hooks can
> >be damaged in some circumstances, leading to false positive
> >matches. That seems to happen when the regexp both: Has
> >uppercase characters (is case-significant), and begins by an
> >'^' anchor.
>
> I found more cases to not work: case-sensivity doesn't matter (I put
> some debug lines in and always see errors for your samples).
>
> The problem is that mailbox expansion is applied to folder-hooks. I'd
> call this a feature and thus your report is both valid and invalid at
> the same time... :(
>
> Please see: mutt_parse_hook() in hook.c and _mutt_expand_path() in
> muttlib.c. The core problem is that '^' is a shortcut for the current
> folder and thus is subject to expansion and is not treated as a regex
> special character. Basically we need a way to distinct between regex and
> "folder" special characters.
>
> Any ideas?
>
> bye, Rocco
> --
> :wq!
>
>
>