[wp-trac] [WordPress Trac] #25709: Searches with stopwords can trigger E_WARNING when PCRE is lacking UTF-8 support
WordPress Trac
noreply at wordpress.org
Sat Oct 26 23:29:51 UTC 2013
#25709: Searches with stopwords can trigger E_WARNING when PCRE is lacking UTF-8
support
------------------------------+--------------------
Reporter: nacin | Owner:
Type: defect (bug) | Status: new
Priority: high | Milestone: 3.7.1
Component: General | Version: 3.7
Severity: major | Resolution:
Keywords: has-patch commit |
------------------------------+--------------------
Comment (by dd32):
> if ( ! $term || ( 1 === strlen( $term ) && preg_match( '/^[a-z]$/i',
$term ) ) )
That doesn't sound right to me, specifically, the strlen() component.
A non-ascii character will always be >1char (unless mbstring overloading
is enabled, but lets not go there) so that preg_match is only checking to
see if a non-a-z ascii character is present.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/25709#comment:15>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list