Download src/php/php-src/ext/libxml/tests/003.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 468 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/libxml/tests/003.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/libxml/tests/003.phpt
-
curl -L -o 003.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/libxml/tests/003.phpt
468 Bytes
| --TEST-- | |
| libxml_use_internal_errors() memory leaks | |
| --EXTENSIONS-- | |
| simplexml | |
| --FILE-- | |
| var_dump(libxml_use_internal_errors(true)); | |
| $xmlstr = <<< XML | |
| <?xml version='1.0' standalone='yes'?> | |
| <movies> | |
| <movie> | |
| <titles>PHP: Behind the Parser</title> | |
| </movie> | |
| </movies> | |
| XML; | |
| simplexml_load_string($xmlstr); | |
| // test memleaks here | |
| var_dump(libxml_use_internal_errors(false)); | |
| echo "Done\n"; | |
| --EXPECT-- | |
| bool(false) | |
| bool(true) | |
| Done | |