php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #79732 Raise Segfault using fn()
Submitted: 2020-06-25 08:27 UTC Modified: 2020-06-25 08:33 UTC
From: php at stampy dot me Assigned:
Status: Duplicate Package: Unknown/Other Function
PHP Version: 7.4.7 OS: MacOS / Docker
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: php at stampy dot me
New email:
PHP Version: OS:

 

 [2020-06-25 08:27 UTC] php at stampy dot me
Description:
------------
The example below causes a segfault when it should error gracefully or loop forever.

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

function fun($str) {
    array_map(fn () => fun($str), $str);
}
fun(['hello world!']);

Expected result:
----------------
Error, or no output, or endless looping

Actual result:
--------------
SegFault

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-06-25 08:33 UTC] nikic@php.net
-Status: Open +Status: Duplicate
 [2020-06-25 08:33 UTC] nikic@php.net
Duplicate of bug #64196.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Apr 20 03:01:28 2024 UTC