Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:77287 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 87115 invoked from network); 17 Sep 2014 14:04:40 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 17 Sep 2014 14:04:40 -0000 Authentication-Results: pb1.pair.com header.from=johannes@schlueters.de; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=johannes@schlueters.de; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain schlueters.de from 217.114.215.10 cause and error) X-PHP-List-Original-Sender: johannes@schlueters.de X-Host-Fingerprint: 217.114.215.10 mail.experimentalworks.net Received: from [217.114.215.10] ([217.114.215.10:37294] helo=mail.experimentalworks.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 06/44-57031-0F499145 for ; Wed, 17 Sep 2014 10:04:33 -0400 Received: by mail.experimentalworks.net (Postfix, from userid 1003) id DDFB8421E3; Wed, 17 Sep 2014 16:04:39 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on km31408.keymachine.de X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=ALL_TRUSTED autolearn=unavailable version=3.3.2 X-Spam-HAM-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP Received: from [192.168.2.31] (ppp-93-104-26-154.dynamic.mnet-online.de [93.104.26.154]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: johannes@schlueters.de) by mail.experimentalworks.net (Postfix) with ESMTPSA id D601A421E2; Wed, 17 Sep 2014 16:04:33 +0200 (CEST) To: Tjerk Meesters Cc: PHP Internals In-Reply-To: <92CB62B9-018E-4C58-819B-E21681242160@gmail.com> References: <92CB62B9-018E-4C58-819B-E21681242160@gmail.com> Content-Type: text/plain; charset="UTF-8" Date: Wed, 17 Sep 2014 16:03:15 +0200 Message-ID: <1410962596.3023.40.camel@guybrush> Mime-Version: 1.0 X-Mailer: Evolution 2.30.3 Content-Transfer-Encoding: 8bit Subject: Re: [PHP-DEV] Fix for #68021 From: johannes@schlueters.de (Johannes =?ISO-8859-1?Q?Schl=FCter?=) On Wed, 2014-09-17 at 21:51 +0800, Tjerk Meesters wrote: > Hi, > > I’ve authored a fix for browscap: > https://github.com/php/php-src/pull/827 > > Bug report: https://bugs.php.net/bug.php?id=68021 > > It replaces the current expression delimiters of \xA7 with a tilde (~) > that’s ASCII compatible and therefore plays nice with UTF-8. > > Seems like a no-brainer to apply this to 5.4 onwards, but perhaps > somebody has a compelling reason why those section symbols are an > absolute necessity. > Do you know that there is no and will never be a useragent string (and thus a regexp) containing the ~ in any valid browscap file? The current \xA7 is a quite safe guess, I'd say. If this is changed is done I'd suggest escaping the regexp accordingly to be on the safe side. johannes P.S. see i.e. "[e-SocietyRobot(http://www.yama.info.waseda.ac.jp/~yamana/es/)]" which seems to exist in the current browscap version. >