You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2014/07/21 15:36:39 UTC

[jira] [Commented] (LUCENE-5839) Regex bug in AnalyzingQueryParser

    [ https://issues.apache.org/jira/browse/LUCENE-5839?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14068511#comment-14068511 ] 

ASF GitHub Bot commented on LUCENE-5839:
----------------------------------------

GitHub user tballison opened a pull request:

    https://github.com/apache/lucene-solr/pull/67

    LUCENE-5839: Fix regex in AnalyzingQueryParser

    LUCENE-5839: Fix regex in AnalyzingQueryParser

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/tballison/lucene-solr trunk

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/lucene-solr/pull/67.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #67
    
----
commit 1eac4382dd1ee7a4319096499335d7f7f28f526a
Author: tballison <ta...@mitre.org>
Date:   2014-07-21T13:22:38Z

    Fix regex in AnalyzingQueryParser

----


> Regex bug in AnalyzingQueryParser
> ---------------------------------
>
>                 Key: LUCENE-5839
>                 URL: https://issues.apache.org/jira/browse/LUCENE-5839
>             Project: Lucene - Core
>          Issue Type: Bug
>          Components: core/queryparser
>    Affects Versions: 4.9
>            Reporter: Tim Allison
>            Priority: Trivial
>
> Dennis Walter recently pointed out this bug on dev@lucene.apache.org:
> "  // gobble escaped chars or find a wildcard character 
>   private final Pattern wildcardPattern = Pattern.compile("(\\.)|([?*]+)");
> The first group will match a literal dot ("."), while its intention seems to be to match a backslash and a single character. So the expression should instead be "(\\\\.)|([?*]+)"  "



--
This message was sent by Atlassian JIRA
(v6.2#6252)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org