Re: [PATCH] Fix M-x tmda-pending for new script output

Stephen Warren <[email protected]> Wed, 30 Jan 2008 20:28:40 -0700
Newsgroups gmane.mail.spam.tmda.devel
Message-ID <[email protected]>
Bob Rogers wrote:
>    After upgrading from 1.1.4 to 1.1.12, I noticed that the tmda-pending
> script now drops the ".msg" from the message file name in "terse"
> output.  Unfortunately, this breaks M-x tmda-pending, which relies on
> the ".msg" suffix to recognize the name.  The attached patch to tmda.el
> fixes the problem, in a way that allows both styles of output to be
> parsed.

I'm not sure the new regex is correct.

The old regex:

"\\([0-9.]+msg\\)[\t ]"

accepts "a sequence of 0-9 or ." followed by ".msg"

whereas the new regex:

\\([0-9.msg]+\\)[\t ]"

accepts "a sequence of 0-9 or . or m or s or g".

Instead, I think the new regex should accept:

accepts "a sequence of 0-9 or ." optionally followed by ".msg"

which I guess might be coded as this, although I'm not familiar with 
Emacs's exact regex syntax:

"\\([0-9.]+\\(.msg\\)?\\)[\t ]"