Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:36198 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 65848 invoked from network); 18 Mar 2008 19:37:22 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 18 Mar 2008 19:37:22 -0000 Authentication-Results: pb1.pair.com header.from=stephen@stephenbach.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=stephen@stephenbach.net; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain stephenbach.net from 208.113.200.5 cause and error) X-PHP-List-Original-Sender: stephen@stephenbach.net X-Host-Fingerprint: 208.113.200.5 lax-green-bigip-5.dreamhost.com Linux 2.4/2.6 Received: from [208.113.200.5] ([208.113.200.5:48450] helo=blingymail-a2.g.dreamhost.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CB/3B-06623-1F910E74 for ; Tue, 18 Mar 2008 14:37:22 -0500 Received: from wkstn35-53.swq.georgetown.edu (wkstn35-53.swq.georgetown.edu [141.161.35.53]) by blingymail-a2.g.dreamhost.com (Postfix) with ESMTP id 924C141343; Tue, 18 Mar 2008 12:37:18 -0700 (PDT) To: Andrei Zmievski Date: Tue, 18 Mar 2008 15:37:16 -0400 User-Agent: KMail/1.9.6 References: <200803172351.12440.stephen@stephenbach.net> <47DFFF31.607@gravitonic.com> In-Reply-To: <47DFFF31.607@gravitonic.com> Cc: internals@lists.php.net MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-ID: <200803181537.16247.stephen@stephenbach.net> Subject: Re: [PHP-DEV] [PATCH] Bug 43477 - Unicode error mode ignored From: stephen@stephenbach.net (Stephen Bach) I'm just suggesting that other error modes should do what they claim to do. Stopping on an illegal sequence is fine, unless the user had called a function telling the converter to do something else. U_CONV_ERROR_STOP: stops on illegal character (the default) U_CONV_ERROR_ESCAPE_*: 5 different modes that escape the illegal sequence in various ways Shouldn't U_CONV_ERROR_SKIP and U_CONV_ERROR_SUBST work the same way? -Stephen On Tuesday 18 March 2008 01:43:13 pm Andrei wrote: > Why would we not want to stop on illegal sequences? > > -Andrei > > Stephen Bach wrote: > > Attached is a simple proposed patch that fixes Bug 43477. Basically, the > > code that set the error mode of the ICU converter was giving it an > > instruction (the context parameter) to only skip or substitute if the > > code point was not represented in the new encoding. However, it still was > > returning an error for illegal sequences. > > > > The test suite returns the same results with or without the patch. Test > > also attached. > > > > -Stephen Bach