php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #70681 Segfault when binding $this of internal instance method to null
Submitted: 2015-10-09 20:38 UTC Modified: 2015-10-09 20:38 UTC
From: nikic@php.net Assigned: nikic
Status: Closed Package: Scripting Engine problem
PHP Version: 7.0.0RC4 OS:
Private report: No CVE-ID:
 [2015-10-09 20:38 UTC] nikic@php.net
Description:
------------
We currently allow binding $this for internal instance methods to NULL.

Test script:
---------------
<?php

$c = (new ReflectionMethod('SplStack', 'count'))->getClosure(new SplStack);
$c = $c->bindTo(null);
var_dump($c());


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-10-09 20:38 UTC] nikic@php.net
-Status: Open +Status: Assigned -Assigned To: +Assigned To: nikic
 [2015-10-09 21:08 UTC] nikic@php.net
Automatic comment on behalf of nikic
Revision: http://git.php.net/?p=php-src.git;a=commit;h=bbae7ddf29192af25a3a776dfc52508c162d2ea6
Log: Fixed bug #70681
 [2015-10-09 21:08 UTC] nikic@php.net
-Status: Assigned +Status: Closed
 [2015-10-13 10:12 UTC] ab@php.net
Automatic comment on behalf of nikic
Revision: http://git.php.net/?p=php-src.git;a=commit;h=bbae7ddf29192af25a3a776dfc52508c162d2ea6
Log: Fixed bug #70681
 
PHP Copyright © 2001-2017 The PHP Group
All rights reserved.
Last updated: Fri Feb 24 01:01:37 2017 UTC