php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72452 Segfault when executing functions.php
Submitted: 2016-06-20 05:32 UTC Modified: 2016-06-28 09:06 UTC
From: ryan dot jentzsch at gmail dot com Assigned: laruence (profile)
Status: Closed Package: Reproducible crash
PHP Version: 7.1Git-2016-06-20 (Git) OS: Linux Mint 17.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: ryan dot jentzsch at gmail dot com
New email:
PHP Version: OS:

 

 [2016-06-20 05:32 UTC] ryan dot jentzsch at gmail dot com
Description:
------------
Segfault when running the referenced script:

Test script:
---------------
https://dl.dropboxusercontent.com/u/32885273/functions.php

Expected result:
----------------
No output.

Actual result:
--------------
$ php --version
PHP 7.1.0-dev (cli) (built: Jun 19 2016 22:18:33) ( ZTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.1.0-dev, Copyright (c) 1998-2016 Zend Technologies
    with Xdebug v2.5.0-dev, Copyright (c) 2002-2016, by Derick Rethans


$ php functions.php 
[1]    19913 segmentation fault  php functions.php


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-06-20 05:42 UTC] ryan dot jentzsch at gmail dot com
I think the parser is choking on the deprecated link() function declaration:

if (! function_exists('DI\link')) {
    /**
     * Helper for referencing another container entry in an object definition.
     *
     * @deprecated \DI\link() has been replaced by \DI\get()
     *
     * @param string $entryName
     *
     * @return EntryReference
     */
    function link($entryName)
    {
        return new EntryReference($entryName);
    }
}

I REMOVED this and the segfault went away. Commenting the code out still threw segfault errors.
 [2016-06-20 09:31 UTC] laruence@php.net
-Status: Open +Status: Feedback
 [2016-06-20 09:31 UTC] laruence@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.


 [2016-06-27 09:34 UTC] ryan dot jentzsch at gmail dot com
-Status: Feedback +Status: Open
 [2016-06-27 09:34 UTC] ryan dot jentzsch at gmail dot com
I just did a git pull and rebuilt PHP and I no longer get a segfault. Please close this issue. Thx.
 [2016-06-28 09:06 UTC] laruence@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: laruence
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Tue Oct 06 17:00:01 2026 UTC