]> granicus.if.org Git - php/commitdiff
MFB: Fixed bug #37569 (WDDX incorrectly encodes high-ascii characters).
authorIlia Alshanetsky <iliaa@php.net>
Thu, 25 May 2006 23:23:15 +0000 (23:23 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Thu, 25 May 2006 23:23:15 +0000 (23:23 +0000)
ext/wddx/tests/bug37569.phpt [new file with mode: 0755]
ext/wddx/wddx.c

diff --git a/ext/wddx/tests/bug37569.phpt b/ext/wddx/tests/bug37569.phpt
new file mode 100755 (executable)
index 0000000..f741d7b
--- /dev/null
@@ -0,0 +1,10 @@
+--TEST--
+Bug #37569 (WDDX incorrectly encodes high-ascii characters)
+--FILE--
+<?php
+echo wddx_serialize_value(chr(1))."\n";
+echo wddx_serialize_value(chr(128))."\n";
+?>
+--EXPECT--
+<wddxPacket version='1.0'><header/><data><string><char code='01'/></string></data></wddxPacket>
+<wddxPacket version='1.0'><header/><data><string><char code='80'/></string></data></wddxPacket>
index 3562c6e9f86d646bb5fc1fad77090e17f21432ac..9eed8bad4764fe8119c7d078913fe8efa70b534d 100644 (file)
 #include "config.h"
 #endif
 
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
 #include "php.h"
 
 #if HAVE_WDDX