Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:18928 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 28400 invoked by uid 1010); 14 Sep 2005 20:12:12 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 28385 invoked from network); 14 Sep 2005 20:12:12 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 Sep 2005 20:12:12 -0000 X-Host-Fingerprint: 81.169.182.136 ajaxatwork.net Linux 2.4/2.6 Received: from ([81.169.182.136:34149] helo=strato.aixcept.de) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id F2/BC-41173-B1488234 for ; Wed, 14 Sep 2005 16:12:11 -0400 Received: from localhost (strato.aixcept.de [81.169.182.136]) by strato.aixcept.de (Postfix) with ESMTP id 18E1D35C36E; Wed, 14 Sep 2005 22:34:53 +0200 (CEST) Date: Wed, 14 Sep 2005 22:12:04 +0200 Reply-To: Marcus Boerger X-Priority: 3 (Normal) Message-ID: <115291175.20050914221204@marcus-boerger.de> To: Antony Dovgal Cc: Andrei Zmievski , php-dev , Dmitry Stogov In-Reply-To: <432872D7.8060606@zend.com> References: <43215A91.8050409@zend.com> <9CF57DC5-A18B-4264-B20B-8552B0BB66F1@gravitonic.com> <432194F7.6000703@zend.com> <463148328.20050914160240@marcus-boerger.de> <432872D7.8060606@zend.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] unserialize() & unicode issues From: helly@php.net (Marcus Boerger) Hello Antony, Wednesday, September 14, 2005, 8:58:31 PM, you wrote: > On 14.09.2005 18:02, Marcus Boerger wrote: >> Hello Antony, >> >> why can't we put a marker there? shouldn't we be able to add a flag >> and allow that flag in older php versions disallowing to load those >> serialized data in case it shows unicode semantics? > You mean adding a marker to be able to fail with a nice error msg? > I don't think the marker is needed for that (see below). >> Right now we'd >> simply fail in case of unicode usage in any serialized data with old >> php versions. > Yes. > And I think it's reasonable as nobody told that the old versions will be forward compatible. >> Adding those types now would at least to show a more >> specific and thus helpful error message. > I suppose it's better to change 4.4.1/5.0.6/5.1 to fail gracefully when they find an unknown prefix ("U:"). >> On te other hand havin the >> semantics flag being optional would allow HEAD to unserialize data >> from older version without any problem. > Didn't get that paragraph... =| > Do we have any problems with serialized data from older versions? > I don't see any of them. Well right now we don't fail gracefully and i don't think we should unless we are dealing with something introduced in later versions that doesn't hurt or to generate helpfull error messages that explicitly tell you what new stuff the serialized data contains the old version being runned cannot deal with (e.g. Unicode data). Best regards, Marcus