mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
# make derik happy
This commit is contained in:
parent
dc8daad70d
commit
64bd1cdbd6
24
ext/standard/tests/strings/bug22904.phpt
Normal file
24
ext/standard/tests/strings/bug22904.phpt
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
--TEST--
|
||||||
|
Bug #22904 (magic mode failed for cybase with '\0')
|
||||||
|
--FILE--
|
||||||
|
<?php
|
||||||
|
ini_set("magic_quotes_sybase","on");
|
||||||
|
test();
|
||||||
|
ini_set("magic_quotes_sybase","off");
|
||||||
|
test();
|
||||||
|
|
||||||
|
function test(){
|
||||||
|
$buf = 'g\g"\0g'."'";
|
||||||
|
$slashed = addslashes($buf);
|
||||||
|
echo "$buf\n";
|
||||||
|
echo "$slashed\n";
|
||||||
|
echo stripslashes($slashed."\n");
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
--EXPECT--
|
||||||
|
g\g"\0g'
|
||||||
|
g\\g"\\0g''
|
||||||
|
g\g"\0g'
|
||||||
|
g\g"\0g'
|
||||||
|
g\\g\"\\0g\'
|
||||||
|
g\g"\0g'
|
Loading…
Reference in New Issue
Block a user