Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:75633 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 5736 invoked from network); 17 Jul 2014 04:01:39 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 17 Jul 2014 04:01:39 -0000 Authentication-Results: pb1.pair.com smtp.mail=laruence@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=laruence@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.217.179 as permitted sender) X-PHP-List-Original-Sender: laruence@gmail.com X-Host-Fingerprint: 209.85.217.179 mail-lb0-f179.google.com Received: from [209.85.217.179] ([209.85.217.179:63894] helo=mail-lb0-f179.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1A/C2-19007-D9A47C35 for ; Thu, 17 Jul 2014 00:01:34 -0400 Received: by mail-lb0-f179.google.com with SMTP id v6so1268608lbi.24 for ; Wed, 16 Jul 2014 21:01:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:from:date:message-id:subject:to:content-type; bh=znIIs7DCwNdh9mXfIzTbMkG5SW3kQ3JfUwwAl+M241I=; b=HTEYzazrfxzuJ4/HUheNcbBhbsdDlcgYwctpd6x6udCN30/WYGZSgkZ6fOJ3X0Trh/ +1FCwShOhjdGbXjtiahdtwEYGDFDpRXBZaTAt9SLnelxMq6r7m3qTqXPMEFU4bIYGq1T kDsRELabamm23eiLCdo2B0XfuYWNJjgtuQF1hgROQz4P3NwInKGYSBvZDp+Y6qpCjWTp 20N7MgnxFFukJO7wuLsdBj4eE2AUu5miw0lpXl/Jj/7WgArn5Uhq1G/5U27mMEBoKfTk zFq83YMv6d/IXlTpZr5QRgLuBsPkVzSy8vD9ZNEEroGxpX2LY1MiP1h+rGTQG0wslZFk S2fA== X-Received: by 10.152.6.170 with SMTP id c10mr29594058laa.9.1405569690463; Wed, 16 Jul 2014 21:01:30 -0700 (PDT) MIME-Version: 1.0 Sender: laruence@gmail.com Received: by 10.114.187.207 with HTTP; Wed, 16 Jul 2014 21:01:10 -0700 (PDT) Date: Thu, 17 Jul 2014 12:01:10 +0800 X-Google-Sender-Auth: iGOMfBgyK-Iihb-4HtiSZtK-DAo Message-ID: To: PHP Internals Content-Type: text/plain; charset=UTF-8 Subject: An BC issue in unserialize From: laruence@php.net (Laruence) Hey: I was trying play with OroCRM. then I find a BC break in PHP-5.6 the usage is : /** * Creates a new instance of the mapped class, without invoking the constructor. * * @return object */ public function newInstance() { if ($this->_prototype === null) { $this->_prototype = unserialize(sprintf('O:%d:"%s":0:{}', strlen($this->name), $this->name)); } return clone $this->_prototype; } it works fine in PHP-5.5, but in 5.6 , the serialize will fail after fix 5328d4289946e260232f3195ba2e0f0eb173d5ef then I found, Stas did a re-fix for that: 342240fd7fb6ac0a287eb6f912c4d61d6274d68c but it seems doesn't go into 5.6.. I am not sure now. should this usage be supported? thanks -- Laruence Xinchen Hui http://www.laruence.com/