php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #146 using exit() in eval() causes crash
Submitted: 1998-03-04 18:50 UTC Modified: 1998-03-13 06:22 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: tomo at arts dot box dot co dot jp Assigned: zeev (profile)
Status: Closed Package: Reproducible Crash
PHP Version: 3.0 Latest CVS OS: FreeBSD 2.2-stable
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: tomo at arts dot box dot co dot jp
New email:
PHP Version: OS:

 

 [1998-03-04 18:50 UTC] tomo at arts dot box dot co dot jp
A following script causes segment violation:

<?php
  eval( "echo('hello'); exit();" );
?>

It seems that the FILE* variable passes as NULL in main.c:
...
   if ( GLOBAL(initialized) & INIT_SCANNER) {
       reset_scanner();
       fclose(GLOBAL(phpin)); /*** here! ***/
       GLOBAL(initialized) &= ~INIT_SCANNER;
   }

# I am running the CGI version.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-03-13 06:22 UTC] zeev
Fixed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 11:01:30 2024 UTC