php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #78531 Crash when using undefined variable as object
Submitted: 2019-09-12 22:34 UTC Modified: 2019-09-12 22:34 UTC
From: dmitry@php.net Assigned: dmitry (profile)
Status: Closed Package: Scripting Engine problem
PHP Version: 7.4Git-2019-09-12 (Git) OS: *
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: dmitry@php.net
New email:
PHP Version: OS:

 

 [2019-09-12 22:34 UTC] dmitry@php.net
Description:
------------
PHP crashes on attempt to modify property of undefined variable

Test script:
---------------
<?php
@$undef->a += 5;
var_dump($undef->a);

Expected result:
----------------
int(5)

Actual result:
--------------
crash

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-09-12 22:34 UTC] dmitry@php.net
-Status: Open +Status: Assigned -Assigned To: +Assigned To: dmitry
 [2019-09-12 22:43 UTC] dmitry@php.net
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=51d9f32dbeae2ffdc6e9f01d4f542a8e03f24baf
Log: Fixed bug #78531 (Crash when using undefined variable as object
 [2019-09-12 22:43 UTC] dmitry@php.net
-Status: Assigned +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 21 12:01:29 2024 UTC