Skip to content

Commit cd64be8

Browse files
committed
Try to run test on windows
1 parent e23fe9c commit cd64be8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ext/libxml/tests/libxml_entity_loading_disabled_by_default.phpt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ libxml_disable_entity_loader()
44
<?php
55
if (!extension_loaded('libxml')) die('skip libxml extension not available');
66
if (!extension_loaded('dom')) die('skip dom extension not available');
7-
if (defined('PHP_WINDOWS_VERSION_MAJOR')) die('skip not for Windows'); ?>
7+
?>
88
--FILE--
99
<?php
1010

@@ -14,7 +14,8 @@ $xml = <<<EOT
1414
<foo>&xxe;</foo>
1515
EOT;
1616

17-
$xml = str_replace('XXE_URI', __DIR__ . '/libxml_disable_entity_loader_payload.txt', $xml);
17+
$dir = str_replace('\\', '/', __DIR__);
18+
$xml = str_replace('XXE_URI', $dir . '/libxml_disable_entity_loader_payload.txt', $xml);
1819

1920
function parseXML1($xml) {
2021
$doc = new DOMDocument();

0 commit comments

Comments
 (0)