Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:74973 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 1602 invoked from network); 18 Jun 2014 08:15:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 18 Jun 2014 08:15:36 -0000 Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 108.166.43.67 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 108.166.43.67 smtp67.ord1c.emailsrvr.com Linux 2.6 Received: from [108.166.43.67] ([108.166.43.67:39673] helo=smtp67.ord1c.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D9/A5-01877-6AA41A35 for ; Wed, 18 Jun 2014 04:15:34 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp17.relay.ord1c.emailsrvr.com (SMTP Server) with ESMTP id 7FAE038047F; Wed, 18 Jun 2014 04:15:31 -0400 (EDT) X-Virus-Scanned: OK Received: by smtp17.relay.ord1c.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id E7962381C62; Wed, 18 Jun 2014 04:15:30 -0400 (EDT) Message-ID: <53A14AA2.9040207@sugarcrm.com> Date: Wed, 18 Jun 2014 01:15:30 -0700 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Ferenc Kovacs CC: julien pauli , Anatoliy Belsky , Remi Collet , PHP Internals References: <53A0C6DD.50705@sugarcrm.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Problems with the fix for the BC break introduced in 5.4.29 and 5.5.13 From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > Back then when Sebastian > proposed ReflectionClass::newInstanceWithoutConstructor() for 5.4, he > himself introduced the only userland class restriction, because as he > mentioned some internal classes would crash if instantiated without a > constructor: > http://marc.info/?l=php-internals&m=131426563418067&w=2 > And it properly considers userland classes extending internal classes as > internal, and prohibits the instantiation for such classes: > http://3v4l.org/Zp4YS Maybe we should use the same thing for serializer, i.e. ce->create_object check? > without their constructors (which would be a nice thing anyways) I don't > see any other way to fix the segfaults while keeping the ability to > instantiate any class (be that an internal class, or a class > implementing Serialize) with ease. If we add ce->create_object check, wouldn't it solve most of the problems? -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227