From: Dmitry Stogov Date: Mon, 27 Mar 2006 14:19:18 +0000 (+0000) Subject: Unicode support X-Git-Tag: RELEASE_1_3~228 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9d9adb2f351efcc5e576298a65ee690435d795cb;p=php Unicode support --- diff --git a/ext/standard/tests/serialize/002.phpt b/ext/standard/tests/serialize/002.phpt index 3085d1cf4f..2ed233988f 100644 --- a/ext/standard/tests/serialize/002.phpt +++ b/ext/standard/tests/serialize/002.phpt @@ -42,3 +42,32 @@ array(3) { object(stdClass)#%d (0) { } ===DONE=== +--UEXPECTF-- +bool(false) +bool(true) +int(823) +unicode(0) "" +unicode(3) "foo" +array(1) { + [0]=> + unicode(2) "12" +} +array(2) { + [0]=> + array(0) { + } + [1]=> + array(0) { + } +} +array(3) { + [0]=> + unicode(3) "foo" + [1]=> + unicode(3) "bar" + [2]=> + unicode(3) "baz" +} +object(stdClass)#%d (0) { +} +===DONE=== diff --git a/ext/standard/var_unserializer.c b/ext/standard/var_unserializer.c index e387f11566..e5a2932aea 100644 --- a/ext/standard/var_unserializer.c +++ b/ext/standard/var_unserializer.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.9.10 on Mon Mar 27 17:29:16 2006 */ +/* Generated by re2c 0.9.10 on Mon Mar 27 17:59:43 2006 */ #line 1 "ext/standard/var_unserializer.re" /* +----------------------------------------------------------------------+ @@ -838,7 +838,7 @@ yy52: *p = YYCURSOR; INIT_PZVAL(*rval); - ZVAL_STRINGL(*rval, str, len, 1); + ZVAL_RT_STRINGL(*rval, str, len, 1); return 1; } #line 845 "ext/standard/var_unserializer.c" diff --git a/ext/standard/var_unserializer.re b/ext/standard/var_unserializer.re index b770f433ba..ff5d823fde 100644 --- a/ext/standard/var_unserializer.re +++ b/ext/standard/var_unserializer.re @@ -507,7 +507,7 @@ PHPAPI int php_var_unserialize(UNSERIALIZE_PARAMETER) *p = YYCURSOR; INIT_PZVAL(*rval); - ZVAL_STRINGL(*rval, str, len, 1); + ZVAL_RT_STRINGL(*rval, str, len, 1); return 1; }