Re: tin (current 1.9.3 snapshot) hangs with pcre problem
Urs Janßen <[email protected]> Mon, 15 Oct 2007 15:24:23 +0200
| Newsgroups | gmane.network.tin.devel |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Oct 15, 2007 at 02:41:48PM +0200, Olaf Dietrich wrote: > > no it just gives the error message (= waitz for two seconds) for _each_ > > (depending on filter type, all inc. read, or just unread) subject in that > > group -> that may take a while. > > Nevertheless I wonder, whether this situation could be handled somewhat > more user-friendly - there are currently 6000 unread articles in the > group, so there is little chance to recover from the error messages. the current code is something like: filter_articles() loops over all articles (in the given scope) and tries to apply the rule via test_regex() which looks if the rule has already been compiled (in that case it would use the compiled result for speed reasons) and if not tries to do so via compile_regex(). compile_regex() (which calls pcre_compile() which does not have an error returncode except storing an error message somewhere) fails, gives an error messag and returns with FALSE which just means no match. outside compile_regex() we do not know anything about the regexp except that it didn't match and we do not have a build cache (which is also true for the first article in the loop). feel free to improve that (but avoid pcre_compile2()). urs -- "Only whimps use tape backup: _real_ men just upload their important stuff on ftp, and let the rest of the world mirror it ;)" - Linus