xref: /PHP-7.0/ext/wddx/tests/bug72790.phpt (revision 8c67460a)
1--TEST--
2Bug #72790: wddx_deserialize null dereference with invalid xml
3--SKIPIF--
4<?php
5if (!extension_loaded('wddx')) {
6    die('skip. wddx not available');
7}
8?>
9--FILE--
10<?php
11
12$xml = <<< XML
13<?xml version='1.0' ?>
14<!DOCTYPE wddxPacket SYSTEM 'wddx_0100.dtd'>
15<wddxPacket version='1.0'>
16        |array>
17                <var name="XXXX">
18                        <boolean value="this">
19                        </boolean>
20                </var>
21                <var name="YYYY">
22                        <var name="UUUU">
23                                <var name="EZEZ">
24                                </var>
25                        </var>
26                </var>
27        </array>
28</wddxPacket>
29XML;
30
31$array = wddx_deserialize($xml);
32var_dump($array);
33?>
34--EXPECT--
35NULL