[PHP-CVS-DAILY] cvs: php-src / ChangeLog

2006-07-13 Thread changelog
changelog   Fri Jul 14 01:30:52 2006 UTC

  Modified files:  
/php-srcChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/php-src/ChangeLog?r1=1.2390r2=1.2391diff_format=u
Index: php-src/ChangeLog
diff -u php-src/ChangeLog:1.2390 php-src/ChangeLog:1.2391
--- php-src/ChangeLog:1.2390Thu Jul 13 01:31:06 2006
+++ php-src/ChangeLog   Fri Jul 14 01:30:51 2006
@@ -1,3 +1,206 @@
+2006-07-13  Andrei Zmievski  [EMAIL PROTECTED]
+
+* ext/standard/string.c:
+  FIXME note
+
+* unicode-progress.txt
+  ext/standard/array.c:
+  Update array_sum() and array_product() (U).
+
+* unicode-progress.txt
+  ext/standard/array.c:
+  Mark a few more funcs.
+
+* unicode-progress.txt
+  ZendEngine2/zend_API.c
+  ext/standard/array.c
+  ext/standard/string.c:
+  - Let the caller output a warning instead of having
+zend_get_unified_string_type() do it.
+  - Mark a few more functions are Unicode compatible.
+
+* unicode-progress.txt
+  ext/standard/array.c:
+  - Make compact() normalize variablem name before checking symtable.
+  - Mark tested/upgraded functions with 'U' flag.
+
+2006-07-13  Antony Dovgal  [EMAIL PROTECTED]
+
+* ext/standard/string.c
+  main/main.c:
+  initialize variables
+
+* main/php_logos.h
+  main/php_logos.h:
+  fix build
+
+2006-07-13  Dmitry Stogov  [EMAIL PROTECTED]
+
+* ext/soap/php_encoding.c
+  ext/soap/php_http.c
+  ext/soap/php_packet_soap.c
+  ext/soap/php_schema.c
+  ext/soap/php_sdl.c
+  ext/soap/php_soap.h
+  ext/soap/soap.c
+  ext/soap/tests/any.phpt
+  ext/soap/tests/classmap002.phpt
+  ext/soap/tests/server007.phpt
+  ext/soap/tests/server008.phpt
+  ext/soap/tests/bugs/bug27722.phpt
+  ext/soap/tests/bugs/bug27742.phpt
+  ext/soap/tests/bugs/bug28751.phpt
+  ext/soap/tests/bugs/bug28969.phpt
+  ext/soap/tests/bugs/bug28985.phpt
+  ext/soap/tests/bugs/bug29061.phpt
+  ext/soap/tests/bugs/bug29109.phpt
+  ext/soap/tests/bugs/bug29236.phpt
+  ext/soap/tests/bugs/bug29795.phpt
+  ext/soap/tests/bugs/bug29830.phpt
+  ext/soap/tests/bugs/bug29839.phpt
+  ext/soap/tests/bugs/bug29844.phpt
+  ext/soap/tests/bugs/bug30045.phpt
+  ext/soap/tests/bugs/bug30106.phpt
+  ext/soap/tests/bugs/bug30175.phpt
+  ext/soap/tests/bugs/bug30799.phpt
+  ext/soap/tests/bugs/bug30928.phpt
+  ext/soap/tests/bugs/bug30994.phpt
+  ext/soap/tests/bugs/bug31422.phpt
+  ext/soap/tests/bugs/bug31695.phpt
+  ext/soap/tests/bugs/bug31755.phpt
+  ext/soap/tests/bugs/bug32776.phpt
+  ext/soap/tests/bugs/bug34449.phpt
+  ext/soap/tests/bugs/bug34453.phpt
+  ext/soap/tests/bugs/bug34643.phpt
+  ext/soap/tests/bugs/bug35142.phpt
+  ext/soap/tests/bugs/bug36226.phpt
+  ext/soap/tests/bugs/bug36575.phpt
+  ext/soap/tests/bugs/bug36629.phpt
+  ext/soap/tests/bugs/bug36908.phpt
+  ext/soap/tests/bugs/bug37278.phpt
+  ext/soap/tests/bugs/bug38004.phpt
+  ext/soap/tests/bugs/bug38005.phpt
+  ext/soap/tests/bugs/bug38055.phpt
+  ext/soap/tests/bugs/bug38067.phpt
+  ext/soap/tests/interop/Round2/Base/r2_base_005p.phpt
+  ext/soap/tests/interop/Round2/Base/r2_base_005s.phpt
+  ext/soap/tests/interop/Round2/Base/r2_base_005w.phpt
+  ext/soap/tests/interop/Round3/GroupE/r3_groupE_list_001w.phpt
+  ext/soap/tests/interop/Round3/GroupE/r3_groupE_list_002w.phpt
+  ext/soap/tests/interop/Round3/GroupE/r3_groupE_list_003w.phpt
+  ext/soap/tests/interop/Round3/GroupE/r3_groupE_list_005w.phpt
+  ext/soap/tests/interop/Round3/GroupE/r3_groupE_list_006w.phpt
+  ext/soap/tests/interop/Round4/GroupI/r4_groupI_xsd_006w.phpt
+  ext/soap/tests/schema/schema004.phpt
+  ext/soap/tests/schema/schema009.phpt
+  ext/soap/tests/schema/schema010.phpt
+  ext/soap/tests/schema/schema011.phpt
+  ext/soap/tests/schema/schema012.phpt
+  ext/soap/tests/schema/schema013.phpt
+  ext/soap/tests/schema/schema014.phpt
+  ext/soap/tests/schema/schema015.phpt
+  ext/soap/tests/schema/schema016.phpt
+  ext/soap/tests/schema/schema017.phpt
+  ext/soap/tests/schema/schema018.phpt
+  ext/soap/tests/schema/schema019.phpt
+  ext/soap/tests/schema/schema020.phpt
+  ext/soap/tests/schema/schema021.phpt
+  ext/soap/tests/schema/schema022.phpt
+  ext/soap/tests/schema/schema030.phpt
+  ext/soap/tests/schema/schema031.phpt
+  ext/soap/tests/schema/schema032.phpt
+  ext/soap/tests/schema/schema033.phpt
+  ext/soap/tests/schema/schema034.phpt
+  ext/soap/tests/schema/schema035.phpt
+  ext/soap/tests/schema/schema036.phpt
+  ext/soap/tests/schema/schema037.phpt
+  ext/soap/tests/schema/schema038.phpt
+  ext/soap/tests/schema/schema039.phpt
+  ext/soap/tests/schema/schema040.phpt
+  

[PHP-CVS-DAILY] cvs: ZendEngine2 / ChangeLog

2006-07-13 Thread changelog
changelog   Fri Jul 14 01:30:53 2006 UTC

  Modified files:  
/ZendEngine2ChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/ChangeLog?r1=1.943r2=1.944diff_format=u
Index: ZendEngine2/ChangeLog
diff -u ZendEngine2/ChangeLog:1.943 ZendEngine2/ChangeLog:1.944
--- ZendEngine2/ChangeLog:1.943 Thu Jul 13 01:31:09 2006
+++ ZendEngine2/ChangeLog   Fri Jul 14 01:30:53 2006
@@ -1,3 +1,10 @@
+2006-07-13  Andrei Zmievski  [EMAIL PROTECTED]
+
+* zend_API.c:
+  - Let the caller output a warning instead of having
+zend_get_unified_string_type() do it.
+  - Mark a few more functions are Unicode compatible.
+
 2006-07-12  Antony Dovgal  [EMAIL PROTECTED]
 
 * (PHP_5_2)
@@ -14445,7 +14452,7 @@
 2003-06-10  Jani Taskinen  [EMAIL PROTECTED]
 
 * zend_multiply.h:
-  - Missing $Id: ChangeLog,v 1.943 2006/07/13 01:31:09 changelog Exp $ tag
+  - Missing $Id: ChangeLog,v 1.944 2006/07/14 01:30:53 changelog Exp $ tag
 
 2003-06-10  James Cox  [EMAIL PROTECTED]
 
@@ -16169,7 +16176,7 @@
   zend_types.h
   zend_variables.c
   zend_variables.h:
-  - Added some missing CVS $Id: ChangeLog,v 1.943 2006/07/13 01:31:09 
changelog Exp $ tags, headers and footers.
+  - Added some missing CVS $Id: ChangeLog,v 1.944 2006/07/14 01:30:53 
changelog Exp $ tags, headers and footers.
 
 2003-01-30  Ilia Alshanetsky  [EMAIL PROTECTED]
 


[PHP-CVS] cvs: php-src /ext/unicode transform.c

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 12:15:01 2006 UTC

  Modified files:  
/php-src/ext/unicodetransform.c 
  Log:
  nuke unused variable
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/unicode/transform.c?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/unicode/transform.c
diff -u php-src/ext/unicode/transform.c:1.3 php-src/ext/unicode/transform.c:1.4
--- php-src/ext/unicode/transform.c:1.3 Thu Jun 15 17:37:48 2006
+++ php-src/ext/unicode/transform.c Thu Jul 13 12:15:01 2006
@@ -14,7 +14,7 @@
+--+
  */
 
-/* $Id: transform.c,v 1.3 2006/06/15 17:37:48 andrei Exp $ */ 
+/* $Id: transform.c,v 1.4 2006/07/13 12:15:01 tony2001 Exp $ */ 
 
 #include php_unicode.h
 
@@ -28,7 +28,7 @@
int result_len = 0;
UTransliterator *trans = NULL;
UErrorCode  status = U_ZERO_ERROR;
-   int32_t capacity, start, limit;
+   int32_t capacity, limit;
 
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, uuu|u, str,
  str_len, from, 
from_len, to, to_len,

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main rfc1867.c

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 12:17:26 2006 UTC

  Modified files:  
/php-src/main   rfc1867.c 
  Log:
  fix C++ comments in C code and comment out unused variable
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/rfc1867.c?r1=1.185r2=1.186diff_format=u
Index: php-src/main/rfc1867.c
diff -u php-src/main/rfc1867.c:1.185 php-src/main/rfc1867.c:1.186
--- php-src/main/rfc1867.c:1.185Wed Mar  8 00:43:29 2006
+++ php-src/main/rfc1867.c  Thu Jul 13 12:17:25 2006
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: rfc1867.c,v 1.185 2006/03/08 00:43:29 pajoye Exp $ */
+/* $Id: rfc1867.c,v 1.186 2006/07/13 12:17:25 tony2001 Exp $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -1145,7 +1145,7 @@
UErrorCode status = U_ZERO_ERROR;
 
char *value = multipart_buffer_read_body(mbuff 
TSRMLS_CC);
-   unsigned int new_val_len; /* Dummy variable */
+   /* unsigned int new_val_len;  Dummy variable */
 
if (value) {
/* UTODO use 'charset' parameter for 
conversion */
@@ -1159,9 +1159,9 @@
}
 
/* UTODO use input filtering */
-   //if (sapi_module.input_filter(PARSE_POST, 
param, value, strlen(value), new_val_len TSRMLS_CC)) {
+   /* if (sapi_module.input_filter(PARSE_POST, 
param, value, strlen(value), new_val_len TSRMLS_CC)) { */
safe_u_php_register_variable(param, 
u_val, u_val_len, array_ptr, 0 TSRMLS_CC);
-   //}
+   /* } */
if (!u_strcasecmp(param, maxfilesize_key, 0)) {
max_file_size = zend_u_strtol(u_val, 
NULL, 10);
}

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/reflection php_reflection.c

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 12:34:30 2006 UTC

  Modified files:  
/php-src/ext/reflection php_reflection.c 
  Log:
  Unicode support in ReflectionParameter::__construct()
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/reflection/php_reflection.c?r1=1.242r2=1.243diff_format=u
Index: php-src/ext/reflection/php_reflection.c
diff -u php-src/ext/reflection/php_reflection.c:1.242 
php-src/ext/reflection/php_reflection.c:1.243
--- php-src/ext/reflection/php_reflection.c:1.242   Mon Jul 10 00:13:50 2006
+++ php-src/ext/reflection/php_reflection.c Thu Jul 13 12:34:30 2006
@@ -20,7 +20,7 @@
+--+
 */
 
-/* $Id: php_reflection.c,v 1.242 2006/07/10 00:13:50 helly Exp $ */
+/* $Id: php_reflection.c,v 1.243 2006/07/13 12:34:30 tony2001 Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1866,10 +1866,12 @@
zend_uint i;
 
position= -1;
-   convert_to_string_ex(parameter);
+   convert_to_text_ex(parameter);
for (i = 0; i  fptr-common.num_args; i++) {
-   /* FIXME: Unicode support??? */
-   if (arg_info[i].name.s  strcmp(arg_info[i].name.s, 
Z_STRVAL_P(parameter)) == 0) {
+   if (Z_TYPE_P(parameter) == IS_STRING  
arg_info[i].name.s  strcmp(arg_info[i].name.s, Z_STRVAL_P(parameter)) == 0) {
+   position= i;
+   break;
+   } else if (Z_TYPE_P(parameter) == IS_UNICODE  
arg_info[i].name.u  u_strcmp(arg_info[i].name.u, Z_USTRVAL_P(parameter)) == 
0) {
position= i;
break;
}
@@ -4836,7 +4838,7 @@
php_info_print_table_start();
php_info_print_table_header(2, Reflection, enabled);
 
-   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.242 
2006/07/10 00:13:50 helly Exp $);
+   php_info_print_table_row(2, Version, $Id: php_reflection.c,v 1.243 
2006/07/13 12:34:30 tony2001 Exp $);
 
php_info_print_table_end();
 } /* }}} */

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /main php_logos.c

2006-07-13 Thread Ilia Alshanetsky
iliaa   Thu Jul 13 15:05:30 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/main   php_logos.c 
  Log:
  Fixed compiler warnings.
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/php_logos.c?r1=1.19.2.1r2=1.19.2.1.2.1diff_format=u
Index: php-src/main/php_logos.c
diff -u php-src/main/php_logos.c:1.19.2.1 php-src/main/php_logos.c:1.19.2.1.2.1
--- php-src/main/php_logos.c:1.19.2.1   Sun Jan  1 12:50:17 2006
+++ php-src/main/php_logos.cThu Jul 13 15:05:30 2006
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: php_logos.c,v 1.19.2.1 2006/01/01 12:50:17 sniper Exp $ */
+/* $Id: php_logos.c,v 1.19.2.1.2.1 2006/07/13 15:05:30 iliaa Exp $ */
 
 #include php.h
 #include logos.h
@@ -27,13 +27,13 @@
 typedef struct _php_info_logo { 
char *mimetype;
int mimelen;
-   unsigned char *data; 
+   const unsigned char *data; 
int size; 
 } php_info_logo;
 
 HashTable phpinfo_logo_hash;
 
-PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, unsigned 
char *data, int size)
+PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, const 
unsigned char *data, int size)
 {
php_info_logo info_logo;
 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main php_logos.c

2006-07-13 Thread Ilia Alshanetsky
iliaa   Thu Jul 13 15:05:42 2006 UTC

  Modified files:  
/php-src/main   php_logos.c 
  Log:
  MFB: Fixed compiler warnings.
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/php_logos.c?r1=1.21r2=1.22diff_format=u
Index: php-src/main/php_logos.c
diff -u php-src/main/php_logos.c:1.21 php-src/main/php_logos.c:1.22
--- php-src/main/php_logos.c:1.21   Thu Mar  2 13:12:45 2006
+++ php-src/main/php_logos.cThu Jul 13 15:05:42 2006
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: php_logos.c,v 1.21 2006/03/02 13:12:45 dmitry Exp $ */
+/* $Id: php_logos.c,v 1.22 2006/07/13 15:05:42 iliaa Exp $ */
 
 #include php.h
 #include logos.h
@@ -27,13 +27,13 @@
 typedef struct _php_info_logo { 
char *mimetype;
int mimelen;
-   unsigned char *data; 
+   const unsigned char *data; 
int size; 
 } php_info_logo;
 
 HashTable phpinfo_logo_hash;
 
-PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, unsigned 
char *data, int size)
+PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, const 
unsigned char *data, int size)
 {
php_info_logo info_logo;
 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /ext/mysqli/tests bug36802.phpt

2006-07-13 Thread Ilia Alshanetsky
iliaa   Thu Jul 13 15:42:43 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/mysqli/tests   bug36802.phpt 
  Log:
  Fixed test for systems where set_charset() method is unavailable.
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mysqli/tests/bug36802.phpt?r1=1.1.2.1r2=1.1.2.1.2.1diff_format=u
Index: php-src/ext/mysqli/tests/bug36802.phpt
diff -u php-src/ext/mysqli/tests/bug36802.phpt:1.1.2.1 
php-src/ext/mysqli/tests/bug36802.phpt:1.1.2.1.2.1
--- php-src/ext/mysqli/tests/bug36802.phpt:1.1.2.1  Fri Mar 24 09:32:24 2006
+++ php-src/ext/mysqli/tests/bug36802.phpt  Thu Jul 13 15:42:43 2006
@@ -17,7 +17,11 @@
$mysql = mysqli_init();
 
/* following operations should not work */
-   $x[0] = @$mysql-set_charset('utf8');
+   if (method_exists($mysql, 'set_charset')) {
+   $x[0] = @$mysql-set_charset('utf8');
+   } else {
+   $x[0] = NULL;
+   }
$x[1] = @$mysql-query(SELECT 'foo' FROM DUAL);
 
/* following operations should work */ 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /main php_logos.h

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 17:02:43 2006 UTC

  Modified files:  
/php-src/main   php_logos.h 
  Log:
  fix build
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/php_logos.h?r1=1.10r2=1.11diff_format=u
Index: php-src/main/php_logos.h
diff -u php-src/main/php_logos.h:1.10 php-src/main/php_logos.h:1.11
--- php-src/main/php_logos.h:1.10   Sun Jan  1 13:09:57 2006
+++ php-src/main/php_logos.hThu Jul 13 17:02:43 2006
@@ -16,14 +16,14 @@
   +--+
 */
 
-/* $Id: php_logos.h,v 1.10 2006/01/01 13:09:57 sniper Exp $ */
+/* $Id: php_logos.h,v 1.11 2006/07/13 17:02:43 tony2001 Exp $ */
 
 
 #ifndef _PHP_LOGOS_H
 #define _PHP_LOGOS_H
 
 BEGIN_EXTERN_C()
-PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, unsigned 
char *data, int size);
+PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, const 
unsigned char *data, int size);
 PHPAPI int php_unregister_info_logo(char *logo_string);
 END_EXTERN_C()
 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src(PHP_5_2) /main php_logos.h

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 17:03:36 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/main   php_logos.h 
  Log:
  fix build
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/php_logos.h?r1=1.9.2.1r2=1.9.2.1.2.1diff_format=u
Index: php-src/main/php_logos.h
diff -u php-src/main/php_logos.h:1.9.2.1 php-src/main/php_logos.h:1.9.2.1.2.1
--- php-src/main/php_logos.h:1.9.2.1Sun Jan  1 12:50:17 2006
+++ php-src/main/php_logos.hThu Jul 13 17:03:35 2006
@@ -16,14 +16,14 @@
   +--+
 */
 
-/* $Id: php_logos.h,v 1.9.2.1 2006/01/01 12:50:17 sniper Exp $ */
+/* $Id: php_logos.h,v 1.9.2.1.2.1 2006/07/13 17:03:35 tony2001 Exp $ */
 
 
 #ifndef _PHP_LOGOS_H
 #define _PHP_LOGOS_H
 
 BEGIN_EXTERN_C()
-PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, unsigned 
char *data, int size);
+PHPAPI int php_register_info_logo(char *logo_string, char *mimetype, const 
unsigned char *data, int size);
 PHPAPI int php_unregister_info_logo(char *logo_string);
 END_EXTERN_C()
 

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src /ext/standard string.c /main main.c

2006-07-13 Thread Antony Dovgal
tony2001Thu Jul 13 17:55:50 2006 UTC

  Modified files:  
/php-src/main   main.c 
/php-src/ext/standard   string.c 
  Log:
  initialize variables
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.695r2=1.696diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.695 php-src/main/main.c:1.696
--- php-src/main/main.c:1.695   Wed Jul 12 17:04:13 2006
+++ php-src/main/main.c Thu Jul 13 17:55:50 2006
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.695 2006/07/12 17:04:13 andrei Exp $ */
+/* $Id: main.c,v 1.696 2006/07/13 17:55:50 tony2001 Exp $ */
 
 /* {{{ includes
  */
@@ -534,7 +534,7 @@
zstr function = NULL_ZSTR;
char *origin;
char *message;
-   char *stage;
+   char *stage = Unknown;
int function_name_is_string = 1;
 
/* get error text into buffer and escape for html if necessary */
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/string.c?r1=1.548r2=1.549diff_format=u
Index: php-src/ext/standard/string.c
diff -u php-src/ext/standard/string.c:1.548 php-src/ext/standard/string.c:1.549
--- php-src/ext/standard/string.c:1.548 Wed Jul 12 12:33:04 2006
+++ php-src/ext/standard/string.c   Thu Jul 13 17:55:50 2006
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: string.c,v 1.548 2006/07/12 12:33:04 tony2001 Exp $ */
+/* $Id: string.c,v 1.549 2006/07/13 17:55:50 tony2001 Exp $ */
 
 /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */
 
@@ -1326,7 +1326,7 @@
UChar *u_token, *u_p, *u_pe;
 
UChar32 ch, th;
-   int32_t start, end, i, j, rem_len;
+   int32_t start = 0, end, i, j, rem_len;
int delim_found, token_present;
int skipped = 0;
 
@@ -2111,7 +2111,7 @@
char needle_char[2];
UChar u_needle_char[3];
int needle_len;
-   char *haystack_copy;
+   char *haystack_copy = NULL;
zstr target;
void *found = NULL;
int found_offset;
@@ -2411,9 +2411,9 @@
zend_uchar str_type;
void *haystack_dup, *needle_dup = NULL;
char needle_char[2];
-   char c;
+   char c = 0;
UChar u_needle_char[3];
-   UChar32 ch;
+   UChar32 ch = 0;
void *found = NULL;
 
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, zz|l, haystack, 
needle, offset) == FAILURE) {
@@ -3908,10 +3908,10 @@
 PHP_FUNCTION(strrev)
 {
zval **str;
-   char *s, *e, *n, *p;
+   char *s, *e, *n = NULL, *p;
int32_t i, x1, x2;
UChar32 ch;
-   UChar *u_s, *u_n, *u_p;
+   UChar *u_s, *u_n = NULL, *u_p;

if (ZEND_NUM_ARGS()!=1 || zend_get_parameters_ex(1, str) == FAILURE) {
WRONG_PARAM_COUNT;
@@ -6316,7 +6316,7 @@
int ac = ZEND_NUM_ARGS();
int count = 0;
void *p, *endp, *tmp;
-   int32_t i, j;
+   int32_t i = 0, j;
char cmp;
 
if (zend_parse_parameters(ac TSRMLS_CC, TT|ll,
@@ -6798,7 +6798,7 @@
 
if (haystack_type == IS_UNICODE) {
int32_t i, j;
-   UChar32 ch1, ch2;
+   UChar32 ch1, ch2 = 0;
 
for (i = 0 ; i  haystack_len ; ) {
U16_NEXT((UChar *)haystack, i, haystack_len, ch1);

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src / unicode-progress.txt /ext/standard array.c

2006-07-13 Thread Andrei Zmievski
andrei  Thu Jul 13 21:08:43 2006 UTC

  Modified files:  
/php-srcunicode-progress.txt 
/php-src/ext/standard   array.c 
  Log:
  - Make compact() normalize variablem name before checking symtable.
  - Mark tested/upgraded functions with 'U' flag.
  
  
http://cvs.php.net/viewvc.cgi/php-src/unicode-progress.txt?r1=1.12r2=1.13diff_format=u
Index: php-src/unicode-progress.txt
diff -u php-src/unicode-progress.txt:1.12 php-src/unicode-progress.txt:1.13
--- php-src/unicode-progress.txt:1.12   Wed Jul 12 23:17:07 2006
+++ php-src/unicode-progress.txtThu Jul 13 21:08:43 2006
@@ -13,9 +13,6 @@
 array_change_key_case()
 Params API, test
 
-array_chunk()
-Test
-
 array_combine()
 Handle IS_UNICODE/IS_STRING keys via add_u_assoc_zval()
 
@@ -106,12 +103,6 @@
 extract()
 Params API, fix php_valid_var_name(), test
 
-compact()
-Test
-
-min(), max()
-Test
-
 natsort(), natcasesort()
 Params API
 Either port strnatcmp() to support Unicode or maybe use ICU's numeric 
collation
@@ -134,7 +125,11 @@
   
   array.c
   ---
+array_chunk() 
+compact()
 count()
+min()
+max()
 
 
   string.c
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.350r2=1.351diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.350 php-src/ext/standard/array.c:1.351
--- php-src/ext/standard/array.c:1.350  Sun Jun 25 19:19:31 2006
+++ php-src/ext/standard/array.cThu Jul 13 21:08:43 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.350 2006/06/25 19:19:31 bjori Exp $ */
+/* $Id: array.c,v 1.351 2006/07/13 21:08:43 andrei Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -291,14 +291,14 @@
return cnt;
 }
 
-/* {{{ proto int count(mixed var [, int mode])
+/* {{{ proto int count(mixed var [, int mode]) U
Count the number of elements in a variable (usually an array) */
 PHP_FUNCTION(count)
 {
zval *array;
long mode = COUNT_NORMAL;

-   if (zend_parse_parameters (ZEND_NUM_ARGS() TSRMLS_CC, z|l, array, 
mode) == FAILURE)
+   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, z|l, array, 
mode) == FAILURE)
return;

switch (Z_TYPE_P(array)) {
@@ -955,7 +955,7 @@
 }
 /* }}} */
 
-/* {{{ proto mixed min(mixed arg1 [, mixed arg2 [, mixed ...]])
+/* {{{ proto mixed min(mixed arg1 [, mixed arg2 [, mixed ...]]) U
Return the lowest value in an array or a series of arguments */
 PHP_FUNCTION(min)
 {
@@ -1005,7 +1005,7 @@
 }
 /* }}} */
 
-/* {{{ proto mixed max(mixed arg1 [, mixed arg2 [, mixed ...]])
+/* {{{ proto mixed max(mixed arg1 [, mixed arg2 [, mixed ...]]) U
Return the highest value in an array or a series of arguments */
 PHP_FUNCTION(max)
 {
@@ -1567,20 +1567,41 @@
 
 static void php_compact_var(HashTable *eg_active_symbol_table, zval 
*return_value, zval *entry)
 {
+   zstr key;
+   int key_len;
+   zend_bool free_key = 0;
zval **value_ptr, *value, *data;
-   
-   if (Z_TYPE_P(entry) == IS_STRING ||
-   Z_TYPE_P(entry) == IS_UNICODE) {
-   if (zend_u_hash_find(eg_active_symbol_table, Z_TYPE_P(entry), 
Z_UNIVAL_P(entry),
-  Z_UNILEN_P(entry)+1, (void 
**)value_ptr) != FAILURE) {
+
+   if (Z_TYPE_P(entry) == IS_STRING || Z_TYPE_P(entry) == IS_UNICODE) {
+   key = Z_UNIVAL_P(entry);
+   key_len = Z_UNILEN_P(entry);
+
+   if (Z_TYPE_P(entry) == IS_UNICODE) {
+   /* Identifier normalization */
+   UChar *norm;
+   int norm_len;
+
+   if (!zend_normalize_identifier(norm, norm_len, key.u, 
key_len, 0)) {
+   zend_error(E_WARNING, Could not normalize 
variable name: %r, key);
+   } else if (norm != key.u) {
+   key.u = norm;
+   key_len = norm_len;
+   free_key = 1;
+   } 
+   }
+   if (zend_u_hash_find(eg_active_symbol_table, Z_TYPE_P(entry), 
key,
+key_len+1, (void 
**)value_ptr) != FAILURE) {
value = *value_ptr;
ALLOC_ZVAL(data);
*data = *value;
zval_copy_ctor(data);
INIT_PZVAL(data);

-   zend_u_hash_update(Z_ARRVAL_P(return_value), 
Z_TYPE_P(entry), Z_UNIVAL_P(entry),
-Z_UNILEN_P(entry)+1, 
data, sizeof(zval *), NULL);
+   zend_u_hash_update(Z_ARRVAL_P(return_value), 
Z_TYPE_P(entry), key,
+ 

[PHP-CVS] cvs: php-src / unicode-progress.txt /ext/standard array.c

2006-07-13 Thread Andrei Zmievski
andrei  Thu Jul 13 22:03:43 2006 UTC

  Modified files:  
/php-srcunicode-progress.txt 
/php-src/ext/standard   array.c 
  Log:
  Mark a few more funcs.
  
  
http://cvs.php.net/viewvc.cgi/php-src/unicode-progress.txt?r1=1.14r2=1.15diff_format=u
Index: php-src/unicode-progress.txt
diff -u php-src/unicode-progress.txt:1.14 php-src/unicode-progress.txt:1.15
--- php-src/unicode-progress.txt:1.14   Thu Jul 13 21:27:48 2006
+++ php-src/unicode-progress.txtThu Jul 13 22:03:42 2006
@@ -104,11 +104,8 @@
 Params API
 Either port strnatcmp() to support Unicode or maybe use ICU's numeric 
collation
 
-sort(), rsort()
-asort(), arsort()
-ksort(), krsort() 
 usort(), uasort(), uksort()
-Test, make sure SORT_LOCALE_STRING uses default collator
+function name normalization, FCI cache
 
 
   Completed
@@ -126,6 +123,10 @@
 range()
 shuffle()
 
+sort(), rsort()
+asort(), arsort()
+ksort(), krsort() 
+
 
   string.c
   
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.352r2=1.353diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.352 php-src/ext/standard/array.c:1.353
--- php-src/ext/standard/array.c:1.352  Thu Jul 13 21:27:48 2006
+++ php-src/ext/standard/array.cThu Jul 13 22:03:42 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.352 2006/07/13 21:27:48 andrei Exp $ */
+/* $Id: array.c,v 1.353 2006/07/13 22:03:42 andrei Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -225,7 +225,7 @@
return array_key_compare(a, b TSRMLS_CC) * -1;
 }
 
-/* {{{ proto bool krsort(array array_arg [, int sort_flags])
+/* {{{ proto bool krsort(array array_arg [, int sort_flags]) U
Sort an array by key value in reverse order */
 PHP_FUNCTION(krsort)
 {
@@ -247,7 +247,7 @@
 }
 /* }}} */
 
-/* {{{ proto bool ksort(array array_arg [, int sort_flags])
+/* {{{ proto bool ksort(array array_arg [, int sort_flags]) U
Sort an array by key */
 PHP_FUNCTION(ksort)
 {
@@ -478,7 +478,7 @@
 /* }}} */
 
 
-/* {{{ proto bool asort(array array_arg [, int sort_flags])
+/* {{{ proto bool asort(array array_arg [, int sort_flags]) U
Sort an array and maintain index association */
 PHP_FUNCTION(asort)
 {
@@ -500,7 +500,7 @@
 }
 /* }}} */
 
-/* {{{ proto bool arsort(array array_arg [, int sort_flags])
+/* {{{ proto bool arsort(array array_arg [, int sort_flags]) U
Sort an array in reverse order and maintain index association */
 PHP_FUNCTION(arsort)
 {
@@ -522,7 +522,7 @@
 }
 /* }}} */
 
-/* {{{ proto bool sort(array array_arg [, int sort_flags])
+/* {{{ proto bool sort(array array_arg [, int sort_flags]) U
Sort an array */
 PHP_FUNCTION(sort)
 {
@@ -544,7 +544,7 @@
 }
 /* }}} */
 
-/* {{{ proto bool rsort(array array_arg [, int sort_flags])
+/* {{{ proto bool rsort(array array_arg [, int sort_flags]) U
Sort an array in reverse order */
 PHP_FUNCTION(rsort)
 {

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-CVS] cvs: php-src / unicode-progress.txt /ext/standard array.c

2006-07-13 Thread Andrei Zmievski
andrei  Thu Jul 13 22:26:43 2006 UTC

  Modified files:  
/php-srcunicode-progress.txt 
/php-src/ext/standard   array.c 
  Log:
  Update array_sum() and array_product() (U).
  
  
http://cvs.php.net/viewvc.cgi/php-src/unicode-progress.txt?r1=1.15r2=1.16diff_format=u
Index: php-src/unicode-progress.txt
diff -u php-src/unicode-progress.txt:1.15 php-src/unicode-progress.txt:1.16
--- php-src/unicode-progress.txt:1.15   Thu Jul 13 22:03:42 2006
+++ php-src/unicode-progress.txtThu Jul 13 22:26:42 2006
@@ -55,9 +55,6 @@
 array_pad()
 Params API, test
 
-array_product()
-Params API, test
-
 array_push(), array_pop(), array_shift(), array_unshift()
 Params API, test
 
@@ -79,9 +76,6 @@
 array_slice()
 Params API, test
 
-array_sum()
-Params API, test
-
 array_unique()
 Params API, test
 
@@ -105,7 +99,7 @@
 Either port strnatcmp() to support Unicode or maybe use ICU's numeric 
collation
 
 usort(), uasort(), uksort()
-function name normalization, FCI cache
+Params API, callback name normalization, FCI cache
 
 
   Completed
@@ -116,6 +110,8 @@
 array_chunk() 
 array_merge()
 array_merge_recursive()
+array_product()
+array_sum()
 compact()
 count()
 min()
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.353r2=1.354diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.353 php-src/ext/standard/array.c:1.354
--- php-src/ext/standard/array.c:1.353  Thu Jul 13 22:03:42 2006
+++ php-src/ext/standard/array.cThu Jul 13 22:26:42 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.353 2006/07/13 22:03:42 andrei Exp $ */
+/* $Id: array.c,v 1.354 2006/07/13 22:26:42 andrei Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -4142,31 +4142,25 @@
 }
 /* }}} */
 
-/* {{{ proto mixed array_sum(array input)
+/* {{{ proto mixed array_sum(array input) U
Returns the sum of the array entries */
 PHP_FUNCTION(array_sum)
 {
-   zval **input,
+   zval *input,
 **entry,
 entry_n;
-   int argc = ZEND_NUM_ARGS();
HashPosition pos;
double dval;

-   if (argc != 1 || zend_get_parameters_ex(argc, input) == FAILURE) {
-   WRONG_PARAM_COUNT;
-   }
-
-   if (Z_TYPE_PP(input) != IS_ARRAY) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, The argument 
should be an array);
+   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, a, input) == 
FAILURE) {
return;
}
 
ZVAL_LONG(return_value, 0);
 
-   for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(input), pos);
-zend_hash_get_current_data_ex(Z_ARRVAL_PP(input), (void 
**)entry, pos) == SUCCESS;
-zend_hash_move_forward_ex(Z_ARRVAL_PP(input), pos)) {
+   for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(input), pos);
+zend_hash_get_current_data_ex(Z_ARRVAL_P(input), (void 
**)entry, pos) == SUCCESS;
+zend_hash_move_forward_ex(Z_ARRVAL_P(input), pos)) {

if (Z_TYPE_PP(entry) == IS_ARRAY || Z_TYPE_PP(entry) == 
IS_OBJECT)
continue;
@@ -4189,34 +4183,28 @@
 }
 /* }}} */
 
-/* {{{ proto mixed array_product(array input)
+/* {{{ proto mixed array_product(array input) U
Returns the product of the array entries */
 PHP_FUNCTION(array_product)
 {
-   zval **input,
+   zval *input,
 **entry,
 entry_n;
-   int argc = ZEND_NUM_ARGS();
HashPosition pos;
double dval;

-   if (argc != 1 || zend_get_parameters_ex(argc, input) == FAILURE) {
-   WRONG_PARAM_COUNT;
-   }
-
-   if (Z_TYPE_PP(input) != IS_ARRAY) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, The argument 
should be an array);
+   if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, a, input) == 
FAILURE) {
return;
}
 
-   if (!zend_hash_num_elements(Z_ARRVAL_PP(input))) {
+   if (!zend_hash_num_elements(Z_ARRVAL_P(input))) {
RETURN_LONG(0);
}
ZVAL_LONG(return_value, 1);
 
-   for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_PP(input), pos);
-zend_hash_get_current_data_ex(Z_ARRVAL_PP(input), (void 
**)entry, pos) == SUCCESS;
-zend_hash_move_forward_ex(Z_ARRVAL_PP(input), pos)) {
+   for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(input), pos);
+zend_hash_get_current_data_ex(Z_ARRVAL_P(input), (void 
**)entry, pos) == SUCCESS;
+zend_hash_move_forward_ex(Z_ARRVAL_P(input), pos)) {

if (Z_TYPE_PP(entry) == IS_ARRAY || Z_TYPE_PP(entry) == 
IS_OBJECT)
continue;

-- 
PHP CVS Mailing 

[PHP-CVS] cvs: php-src /ext/standard string.c

2006-07-13 Thread Andrei Zmievski
andrei  Thu Jul 13 22:26:50 2006 UTC

  Modified files:  
/php-src/ext/standard   string.c 
  Log:
  FIXME note
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/string.c?r1=1.550r2=1.551diff_format=u
Index: php-src/ext/standard/string.c
diff -u php-src/ext/standard/string.c:1.550 php-src/ext/standard/string.c:1.551
--- php-src/ext/standard/string.c:1.550 Thu Jul 13 21:27:48 2006
+++ php-src/ext/standard/string.c   Thu Jul 13 22:26:50 2006
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: string.c,v 1.550 2006/07/13 21:27:48 andrei Exp $ */
+/* $Id: string.c,v 1.551 2006/07/13 22:26:50 andrei Exp $ */
 
 /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */
 
@@ -4065,6 +4065,7 @@
sum += php_u_similar_char(txt1, pos1, txt2, pos2);
}
if ((pos1 + end1  len1)  (pos2 + end2  len2)) {
+   /* FIXME should this be calling php_u_similar_char? */
sum += php_similar_char((UChar *)txt1+pos1+end1, 
len1-pos1-end1,
(UChar 
*)txt2+pos2+end2, len2-pos2-end2);
}

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php