commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (NET-526) Avoid greedy matches within a regex
Date Thu, 20 Feb 2014 14:41:19 GMT

     [ https://issues.apache.org/jira/browse/NET-526?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Sebb updated NET-526:
---------------------

    Issue Type: Improvement  (was: Bug)

> Avoid greedy matches within a regex
> -----------------------------------
>
>                 Key: NET-526
>                 URL: https://issues.apache.org/jira/browse/NET-526
>             Project: Commons Net
>          Issue Type: Improvement
>            Reporter: Sebb
>
> Some of the FTP directory parsers use greedy qualifiers - ".*" - within a regex.
> This can be expensive, as it may require backtracking.
> It's usually better to use a reluctant qualifier - e.g. ".*?" - except at the end of
an RE.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message