dmitry Tue Aug 16 11:09:53 2005 EDT
Modified files:
/php-src/ext/dom/tests bug28817.phpt
/php-src/ext/simplexml simplexml.c
/php-src/ext/simplexml/tests008.phpt 009.phpt 015.phpt 022.phpt
/php-src/ext/splspl_sxe.c
/php-src/ext/spl/tests sxe_002.phpt sxe_003.phpt sxe_004.phpt
/php-src/ext/sqlite sqlite.c
/php-src/ext/sqlite/tests sqlite_002.phpt sqlite_003.phpt
sqlite_005.phpt sqlite_006.phpt
sqlite_007.phpt sqlite_008.phpt
sqlite_009.phpt sqlite_010.phpt
sqlite_011.phpt sqlite_012.phpt
sqlite_013.phpt sqlite_014.phpt
sqlite_015.phpt sqlite_016.phpt
sqlite_019.phpt sqlite_022.phpt
sqlite_023.phpt sqlite_024.phpt
sqlite_025.phpt sqlite_026.phpt
sqlite_oo_002.phpt sqlite_oo_003.phpt
sqlite_oo_008.phpt sqlite_oo_009.phpt
sqlite_oo_010.phpt sqlite_oo_011.phpt
sqlite_oo_012.phpt sqlite_oo_013.phpt
sqlite_oo_014.phpt sqlite_oo_015.phpt
sqlite_oo_016.phpt sqlite_oo_020.phpt
sqlite_oo_021.phpt sqlite_oo_022.phpt
sqlite_oo_024.phpt sqlite_oo_025.phpt
sqlite_oo_026.phpt sqlite_oo_028.phpt
sqlite_oo_030.phpt
Log:
Unicode support
http://cvs.php.net/diff.php/php-src/ext/dom/tests/bug28817.phpt?r1=1.1r2=1.2ty=u
Index: php-src/ext/dom/tests/bug28817.phpt
diff -u php-src/ext/dom/tests/bug28817.phpt:1.1
php-src/ext/dom/tests/bug28817.phpt:1.2
--- php-src/ext/dom/tests/bug28817.phpt:1.1 Sat Dec 4 06:40:10 2004
+++ php-src/ext/dom/tests/bug28817.phpt Tue Aug 16 11:09:42 2005
@@ -36,3 +36,15 @@
string(4) tiro
}
string(30) Cessante causa cessat effectus
+--UEXPECTF--
+array(4) {
+ [0]=
+ unicode(5) bonus
+ [1]=
+ unicode(3) vir
+ [2]=
+ unicode(6) semper
+ [3]=
+ unicode(4) tiro
+}
+unicode(30) Cessante causa cessat effectus
http://cvs.php.net/diff.php/php-src/ext/simplexml/simplexml.c?r1=1.155r2=1.156ty=u
Index: php-src/ext/simplexml/simplexml.c
diff -u php-src/ext/simplexml/simplexml.c:1.155
php-src/ext/simplexml/simplexml.c:1.156
--- php-src/ext/simplexml/simplexml.c:1.155 Tue Aug 16 02:04:58 2005
+++ php-src/ext/simplexml/simplexml.c Tue Aug 16 11:09:44 2005
@@ -18,7 +18,7 @@
+--+
*/
-/* $Id: simplexml.c,v 1.155 2005/08/16 06:04:58 rolland Exp $ */
+/* $Id: simplexml.c,v 1.156 2005/08/16 15:09:44 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include config.h
@@ -280,6 +280,7 @@
case IS_BOOL:
case IS_DOUBLE:
case IS_NULL:
+ case IS_UNICODE:
if (value-refcount 1) {
value_copy = *value;
zval_copy_ctor(value_copy);
@@ -288,6 +289,7 @@
convert_to_string(value);
/* break missing intentionally */
case IS_STRING:
+ case IS_BINARY:
xmlNodeSetContentLen(node, Z_STRVAL_P(value),
Z_STRLEN_P(value));
if (value == value_copy) {
zval_dtor(value);
@@ -427,8 +429,10 @@
case IS_BOOL:
case IS_DOUBLE:
case IS_NULL:
+ case IS_UNICODE:
convert_to_string(value);
case IS_STRING:
+ case IS_BINARY:
newnode =
(xmlNodePtr)xmlNewProp(node, name, Z_STRVAL_P(value));
break;
default:
@@ -511,8 +515,10 @@
node = sxe_get_element_by_offset(sxe,
Z_LVAL_P(member), node);
}
else {
+ zval tmp_zv;
+
if (Z_TYPE_P(member) != IS_STRING) {
- zval tmp_zv = *member;
+ tmp_zv = *member;
zval_copy_ctor(tmp_zv);
member = tmp_zv;
convert_to_string(member);
@@ -526,7 +532,10 @@