Bug #71536 [Ver->Csd]: Access Violation crashes php-cgi.exe

From: Date: Sun, 28 Feb 2016 10:08:15 +0000
Subject: Bug #71536 [Ver->Csd]: Access Violation crashes php-cgi.exe
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-199516@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=71536&edit=1

 ID:                 71536
 Updated by:         ab@php.net
 Reported by:        rieger at racecore dot de
 Summary:            Access Violation crashes php-cgi.exe
-Status:             Verified
+Status:             Closed
 Type:               Bug
 Package:            XML Writer
 Operating System:   Windows 7 Prof SP1 [6.1.7]
 PHP Version:        7.0.3
 Assigned To:        ab
 Block user comment: N
 Private report:     N

 New Comment:

Automatic comment on behalf of ab
Revision: http://git.php.net/?p=php-src.git;a=commit;h=93592a9c08c37184ebcb5c1274f240d257e3e3e1
Log: Fix bug #71536 Access Violation crashes php-cgi.exe


Previous Comments:
------------------------------------------------------------------------
[2016-02-24 20:09:35] ab@php.net

Excellent! Thanks for the good repro case, working towards the fix.

Thanks.

------------------------------------------------------------------------
[2016-02-24 14:39:10] Rieger at racecore dot de

Funny - only with the die function this script crashes?!


<?php

class Test {
    public static function init()
    {
        // foo
        $xml = new \XMLWriter();
        $xml->openUri('php://memory');
        $xml->setIndent(false);
        $xml->startDocument('1.0', 'UTF-8');
        $xml->startElement('response');
        die();                             // crashes with die()
    }
}

Test::init();

------------------------------------------------------------------------
[2016-02-24 14:35:28] rieger at racecore dot de

Success. Could reproduce the issue with this test script \o/


<?php

class Test {
    public static function init()
    {
        $xml = new \XMLWriter();
        $xml->openUri('php://memory');
        $xml->setIndent(false);
        $xml->startDocument('1.0', 'UTF-8');
        $xml->startElement('response');
    }
}

Test::init();

------------------------------------------------------------------------
[2016-02-24 14:19:26] rieger at racecore dot de

I will give it a second try to isolate this bug in a single test file. Thanks for the reply.

------------------------------------------------------------------------
[2016-02-24 14:06:23] ab@php.net

Thanks for the report with a good backtrace. From the backtrace is to see, that the issue is related
to the memory stream wrapper on request shutdown. As you say, the snippet alone doesn't
reproduce the issue. Could you maybe play with the preceding part of the script to extract some
reproduce case? I was playing around the BT to construct a reproduce case, but so far no repro.

Thanks.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=71536


--
Edit this bug report at https://bugs.php.net/bug.php?id=71536&edit=1


Thread (7 messages)

« previous php.bugs (#199516) next »