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

2004-12-04 Thread changelog
changelog   Sat Dec  4 20:32:43 2004 EDT

  Modified files:  
/php-srcChangeLog 
  Log:
  ChangeLog update
  http://cvs.php.net/diff.php/php-src/ChangeLog?r1=1.1823r2=1.1824ty=u
Index: php-src/ChangeLog
diff -u php-src/ChangeLog:1.1823 php-src/ChangeLog:1.1824
--- php-src/ChangeLog:1.1823Fri Dec  3 20:32:05 2004
+++ php-src/ChangeLog   Sat Dec  4 20:32:43 2004
@@ -1,3 +1,256 @@
+2004-12-04  Rasmus Lerdorf  [EMAIL PROTECTED]
+
+* sapi/apache/php_apache.c:
+  Fix proto
+
+2004-12-04  Rob Richards  [EMAIL PROTECTED]
+
+* (PHP_5_0)
+  NEWS:
+  BFN
+
+* (PHP_5_0)
+  ext/dom/php_dom.c
+  ext/dom/tests/bug28817.phpt:
+  MFH: Fixed bug #28817 (Var problem when extending domDocument). (Georg)
+  add test
+
+* ext/dom/tests/bug28817.phpt:
+  
+  add test
+
+* ext/dom/php_dom.c:
+  Fixed bug #28817 (Var problem when extending domDocument). (Georg)
+
+2004-12-04  Georg Richter  [EMAIL PROTECTED]
+
+* (PHP_5_0)
+  NEWS:
+  fixed bug #30890
+
+* (PHP_5_0)
+  ext/mysqli/mysqli.c
+  ext/mysqli/mysqli_prop.c
+  ext/mysqli/tests/001.phpt
+  ext/mysqli/tests/002.phpt
+  ext/mysqli/tests/003.phpt
+  ext/mysqli/tests/004.phpt
+  ext/mysqli/tests/005.phpt
+  ext/mysqli/tests/006.phpt
+  ext/mysqli/tests/007.phpt
+  ext/mysqli/tests/008.phpt
+  ext/mysqli/tests/009.phpt
+  ext/mysqli/tests/010.phpt
+  ext/mysqli/tests/011.phpt
+  ext/mysqli/tests/012.phpt
+  ext/mysqli/tests/013.phpt
+  ext/mysqli/tests/014.phpt
+  ext/mysqli/tests/015.phpt
+  ext/mysqli/tests/016.phpt
+  ext/mysqli/tests/017.phpt
+  ext/mysqli/tests/018.phpt
+  ext/mysqli/tests/019.phpt
+  ext/mysqli/tests/020.phpt
+  ext/mysqli/tests/021.phpt
+  ext/mysqli/tests/022.phpt
+  ext/mysqli/tests/023.phpt
+  ext/mysqli/tests/024.phpt
+  ext/mysqli/tests/025.phpt
+  ext/mysqli/tests/026.phpt
+  ext/mysqli/tests/027.phpt
+  ext/mysqli/tests/028.phpt
+  ext/mysqli/tests/029.phpt
+  ext/mysqli/tests/030.phpt
+  ext/mysqli/tests/031.phpt
+  ext/mysqli/tests/032.phpt
+  ext/mysqli/tests/033.phpt
+  ext/mysqli/tests/034.phpt
+  ext/mysqli/tests/035.phpt
+  ext/mysqli/tests/036.phpt
+  ext/mysqli/tests/037.phpt
+  ext/mysqli/tests/038.phpt
+  ext/mysqli/tests/039.phpt
+  ext/mysqli/tests/040.phpt
+  ext/mysqli/tests/041.phpt
+  ext/mysqli/tests/042.phpt
+  ext/mysqli/tests/043.phpt
+  ext/mysqli/tests/044.phpt
+  ext/mysqli/tests/045.phpt
+  ext/mysqli/tests/046.phpt
+  ext/mysqli/tests/047.phpt
+  ext/mysqli/tests/048.phpt
+  ext/mysqli/tests/049.phpt
+  ext/mysqli/tests/050.phpt
+  ext/mysqli/tests/051.phpt
+  ext/mysqli/tests/052.phpt
+  ext/mysqli/tests/053.phpt
+  ext/mysqli/tests/054.phpt
+  ext/mysqli/tests/055.phpt
+  ext/mysqli/tests/056.phpt
+  ext/mysqli/tests/057.phpt
+  ext/mysqli/tests/058.phpt
+  ext/mysqli/tests/059.phpt
+  ext/mysqli/tests/060.phpt
+  ext/mysqli/tests/061.phpt
+  ext/mysqli/tests/bug29311.phpt
+  ext/mysqli/tests/bug30967.phpt:
+  MFH:
+   fix for bug #28817 (properties don't work in extended class)
+   fix for bug #30890 (testsuite)
+
+* ext/mysqli/tests/001.phpt
+  ext/mysqli/tests/002.phpt
+  ext/mysqli/tests/003.phpt
+  ext/mysqli/tests/004.phpt
+  ext/mysqli/tests/005.phpt
+  ext/mysqli/tests/006.phpt
+  ext/mysqli/tests/007.phpt
+  ext/mysqli/tests/008.phpt
+  ext/mysqli/tests/009.phpt
+  ext/mysqli/tests/010.phpt
+  ext/mysqli/tests/011.phpt
+  ext/mysqli/tests/012.phpt
+  ext/mysqli/tests/013.phpt
+  ext/mysqli/tests/014.phpt
+  ext/mysqli/tests/015.phpt
+  ext/mysqli/tests/016.phpt
+  ext/mysqli/tests/017.phpt
+  ext/mysqli/tests/018.phpt
+  ext/mysqli/tests/019.phpt
+  ext/mysqli/tests/020.phpt
+  ext/mysqli/tests/021.phpt
+  ext/mysqli/tests/022.phpt
+  ext/mysqli/tests/023.phpt
+  ext/mysqli/tests/024.phpt
+  ext/mysqli/tests/025.phpt
+  ext/mysqli/tests/026.phpt
+  ext/mysqli/tests/027.phpt
+  ext/mysqli/tests/028.phpt
+  ext/mysqli/tests/029.phpt
+  ext/mysqli/tests/030.phpt
+  ext/mysqli/tests/031.phpt
+  ext/mysqli/tests/032.phpt
+  ext/mysqli/tests/033.phpt
+  ext/mysqli/tests/034.phpt
+  ext/mysqli/tests/035.phpt
+  ext/mysqli/tests/036.phpt
+  ext/mysqli/tests/037.phpt
+  ext/mysqli/tests/038.phpt
+  ext/mysqli/tests/039.phpt
+  ext/mysqli/tests/040.phpt
+  ext/mysqli/tests/041.phpt
+  ext/mysqli/tests/042.phpt
+  ext/mysqli/tests/043.phpt
+  ext/mysqli/tests/044.phpt
+  ext/mysqli/tests/045.phpt
+  ext/mysqli/tests/046.phpt
+  ext/mysqli/tests/047.phpt
+  ext/mysqli/tests/048.phpt
+  ext/mysqli/tests/049.phpt
+  ext/mysqli/tests/050.phpt
+  

[PHP-CVS] cvs: php-src /ext/mysqli mysqli.c mysqli_prop.c /ext/mysqli/tests 001.phpt 002.phpt 003.phpt 004.phpt 005.phpt 006.phpt 007.phpt 008.phpt 009.phpt 010.phpt 011.phpt 012.phpt 013.phpt 014.phpt 015.phpt 016.phpt 017.phpt 018.phpt 019.phpt 020.phpt 021.phpt 022.phpt 023.phpt 024.phpt 025.phpt 026.phpt 027.phpt 028.phpt 029.phpt 030.phpt 031.phpt 032.phpt 033.phpt 034.phpt 035.phpt 036.phpt 037.phpt 038.phpt 039.phpt 040.phpt 041.phpt 042.phpt 043.phpt 044.phpt 045.phpt 046.phpt 047.phpt 048.phpt 049.phpt 050.phpt 051.phpt 052.phpt 053.phpt 054.phpt 055.phpt 056.phpt 057.phpt 058.phpt 059.phpt 060.phpt 061.phpt bug28817.phpt bug29311.phpt bug30967.phpt

2004-12-04 Thread Georg Richter
georg   Sat Dec  4 03:16:05 2004 EDT

  Added files: 
/php-src/ext/mysqli/tests   bug28817.phpt 

  Modified files:  
/php-src/ext/mysqli mysqli.c mysqli_prop.c 
/php-src/ext/mysqli/tests   001.phpt 002.phpt 003.phpt 004.phpt 
005.phpt 006.phpt 007.phpt 008.phpt 
009.phpt 010.phpt 011.phpt 012.phpt 
013.phpt 014.phpt 015.phpt 016.phpt 
017.phpt 018.phpt 019.phpt 020.phpt 
021.phpt 022.phpt 023.phpt 024.phpt 
025.phpt 026.phpt 027.phpt 028.phpt 
029.phpt 030.phpt 031.phpt 032.phpt 
033.phpt 034.phpt 035.phpt 036.phpt 
037.phpt 038.phpt 039.phpt 040.phpt 
041.phpt 042.phpt 043.phpt 044.phpt 
045.phpt 046.phpt 047.phpt 048.phpt 
049.phpt 050.phpt 051.phpt 052.phpt 
053.phpt 054.phpt 055.phpt 056.phpt 
057.phpt 058.phpt 059.phpt 060.phpt 
061.phpt bug29311.phpt bug30967.phpt 
  Log:
  Fixed bug #30890 (testsuite)
  Fixed bug #28817 (property problems in extended class)
  
  http://cvs.php.net/diff.php/php-src/ext/mysqli/mysqli.c?r1=1.53r2=1.54ty=u
Index: php-src/ext/mysqli/mysqli.c
diff -u php-src/ext/mysqli/mysqli.c:1.53 php-src/ext/mysqli/mysqli.c:1.54
--- php-src/ext/mysqli/mysqli.c:1.53Fri Dec  3 02:56:18 2004
+++ php-src/ext/mysqli/mysqli.c Sat Dec  4 03:16:03 2004
@@ -15,7 +15,7 @@
   | Author: Georg Richter [EMAIL PROTECTED]|
   +--+
 
-  $Id: mysqli.c,v 1.53 2004/12/03 07:56:18 georg Exp $ 
+  $Id: mysqli.c,v 1.54 2004/12/04 08:16:03 georg Exp $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -179,11 +179,6 @@
ret = FAILURE;
obj = (mysqli_object *)zend_objects_get_address(object TSRMLS_CC);
 
-   if (!obj-valid) {
-   retval = EG(uninitialized_zval_ptr);
-   return(retval);
-   }
-
if (member-type != IS_STRING) {
tmp_member = *member;
zval_copy_ctor(tmp_member);
@@ -194,6 +189,7 @@
if (obj-prop_handler != NULL) {
ret = zend_hash_find(obj-prop_handler, Z_STRVAL_P(member), 
Z_STRLEN_P(member)+1, (void **) hnd);
}
+
if (ret == SUCCESS) {
 
/* check if mysqli object is still valid */
@@ -223,6 +219,7 @@
} else {
std_hnd = zend_get_std_object_handlers();
retval = std_hnd-read_property(object, member, type TSRMLS_CC);
+   retval-refcount = 1;
}
 
if (member == tmp_member) {
http://cvs.php.net/diff.php/php-src/ext/mysqli/mysqli_prop.c?r1=1.15r2=1.16ty=u
Index: php-src/ext/mysqli/mysqli_prop.c
diff -u php-src/ext/mysqli/mysqli_prop.c:1.15 
php-src/ext/mysqli/mysqli_prop.c:1.16
--- php-src/ext/mysqli/mysqli_prop.c:1.15   Mon Jul 26 01:44:06 2004
+++ php-src/ext/mysqli/mysqli_prop.cSat Dec  4 03:16:04 2004
@@ -15,7 +15,7 @@
   | Author: Georg Richter [EMAIL PROTECTED]|
   +--+
 
-  $Id: mysqli_prop.c,v 1.15 2004/07/26 05:44:06 georg Exp $ 
+  $Id: mysqli_prop.c,v 1.16 2004/12/04 08:16:04 georg Exp $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -29,6 +29,13 @@
 #include ext/standard/info.h
 #include php_mysqli.h
 
+#define CHECK_OBJECT() \
+   if (!obj-valid) { \
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Property access is 
not allowed yet. Call the default constructor of the object first); \
+   ZVAL_NULL(*retval); \
+   return SUCCESS; \
+   } \
+
 #define MYSQLI_GET_MYSQL() \
 MYSQL *p = (MYSQL *)((MY_MYSQL *)((MYSQLI_RESOURCE *)(obj-ptr))-ptr)-mysql;
 
@@ -41,9 +48,10 @@
 #define MYSQLI_MAP_PROPERTY_FUNC_LONG( __func, __int_func, __get_type, 
__ret_type)\
 int __func(mysqli_object *obj, zval **retval TSRMLS_DC) \
 {\
+   ALLOC_ZVAL(*retval); \
+   CHECK_OBJECT(); \
__ret_type l;\
__get_type;\
-   ALLOC_ZVAL(*retval);\
if (!p) {\
ZVAL_NULL(*retval);\
} else {\
@@ -63,8 +71,9 @@
 int __func(mysqli_object *obj, zval **retval TSRMLS_DC)\
 {\
char *c;\
+   ALLOC_ZVAL(*retval); \
+   CHECK_OBJECT(); \
__get_type;\
-   ALLOC_ZVAL(*retval);\
if (!p) {\
ZVAL_NULL(*retval);\
} else {\
@@ -95,18 +104,6 @@
return SUCCESS;
 }
 /* }}} */
-/* {{{ property link_test_read */
-int link_test_read(mysqli_object *obj, zval **retval TSRMLS_DC)
-{
-   longi;
-   ALLOC_ZVAL(*retval);
-   array_init(*retval);
-
-   for (i=0; i  10; 

[PHP-CVS] cvs: php-src /ext/mysqli/tests 001.phpt 002.phpt 003.phpt 004.phpt 005.phpt 006.phpt 007.phpt 008.phpt 009.phpt 010.phpt 011.phpt 012.phpt 013.phpt 014.phpt 015.phpt 016.phpt 017.phpt 018.phpt 019.phpt 020.phpt 021.phpt 022.phpt 023.phpt 024.phpt 025.phpt 026.phpt 027.phpt 028.phpt 029.phpt 030.phpt 031.phpt 032.phpt 033.phpt 034.phpt 035.phpt 036.phpt 037.phpt 038.phpt 039.phpt 040.phpt 041.phpt 042.phpt 043.phpt 044.phpt 045.phpt 046.phpt 047.phpt 048.phpt 049.phpt 050.phpt 051.phpt 052.phpt 053.phpt 054.phpt 055.phpt 056.phpt 057.phpt 058.phpt 059.phpt 060.phpt 061.phpt bug28817.phpt bug29311.phpt bug30967.phpt skipif.inc

2004-12-04 Thread Georg Richter
georg   Sat Dec  4 03:50:35 2004 EDT

  Added files: 
/php-src/ext/mysqli/tests   skipif.inc 

  Modified files:  
/php-src/ext/mysqli/tests   001.phpt 002.phpt 003.phpt 004.phpt 
005.phpt 006.phpt 007.phpt 008.phpt 
009.phpt 010.phpt 011.phpt 012.phpt 
013.phpt 014.phpt 015.phpt 016.phpt 
017.phpt 018.phpt 019.phpt 020.phpt 
021.phpt 022.phpt 023.phpt 024.phpt 
025.phpt 026.phpt 027.phpt 028.phpt 
029.phpt 030.phpt 031.phpt 032.phpt 
033.phpt 034.phpt 035.phpt 036.phpt 
037.phpt 038.phpt 039.phpt 040.phpt 
041.phpt 042.phpt 043.phpt 044.phpt 
045.phpt 046.phpt 047.phpt 048.phpt 
049.phpt 050.phpt 051.phpt 052.phpt 
053.phpt 054.phpt 055.phpt 056.phpt 
057.phpt 058.phpt 059.phpt 060.phpt 
061.phpt bug28817.phpt bug29311.phpt 
bug30967.phpt 
  Log:
  added skipif section
  
  http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/001.phpt?r1=1.4r2=1.5ty=u
Index: php-src/ext/mysqli/tests/001.phpt
diff -u php-src/ext/mysqli/tests/001.phpt:1.4 
php-src/ext/mysqli/tests/001.phpt:1.5
--- php-src/ext/mysqli/tests/001.phpt:1.4   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/001.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli connect
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/002.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/002.phpt
diff -u php-src/ext/mysqli/tests/002.phpt:1.3 
php-src/ext/mysqli/tests/002.phpt:1.4
--- php-src/ext/mysqli/tests/002.phpt:1.3   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/002.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli bind_result 1 
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/003.phpt?r1=1.4r2=1.5ty=u
Index: php-src/ext/mysqli/tests/003.phpt
diff -u php-src/ext/mysqli/tests/003.phpt:1.4 
php-src/ext/mysqli/tests/003.phpt:1.5
--- php-src/ext/mysqli/tests/003.phpt:1.4   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/003.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli connect
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/004.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/004.phpt
diff -u php-src/ext/mysqli/tests/004.phpt:1.3 
php-src/ext/mysqli/tests/004.phpt:1.4
--- php-src/ext/mysqli/tests/004.phpt:1.3   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/004.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli fetch char/text 
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include (connect.inc);
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/005.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/005.phpt
diff -u php-src/ext/mysqli/tests/005.phpt:1.3 
php-src/ext/mysqli/tests/005.phpt:1.4
--- php-src/ext/mysqli/tests/005.phpt:1.3   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/005.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli fetch char/text long 
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/006.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/006.phpt
diff -u php-src/ext/mysqli/tests/006.phpt:1.3 
php-src/ext/mysqli/tests/006.phpt:1.4
--- php-src/ext/mysqli/tests/006.phpt:1.3   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/006.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli fetch long values
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/007.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/007.phpt
diff -u php-src/ext/mysqli/tests/007.phpt:1.3 
php-src/ext/mysqli/tests/007.phpt:1.4
--- php-src/ext/mysqli/tests/007.phpt:1.3   Sat Dec  4 03:16:04 2004
+++ php-src/ext/mysqli/tests/007.phpt   Sat Dec  4 03:50:33 2004
@@ -1,5 +1,7 @@
 --TEST--
 mysqli fetch short values
+--SKIPIF--
+?php require_once('skipif.inc'); ?
 --FILE--
 ?php
include connect.inc;
http://cvs.php.net/diff.php/php-src/ext/mysqli/tests/008.phpt?r1=1.3r2=1.4ty=u
Index: php-src/ext/mysqli/tests/008.phpt
diff -u php-src/ext/mysqli/tests/008.phpt:1.3 
php-src/ext/mysqli/tests/008.phpt:1.4
--- php-src/ext/mysqli/tests/008.phpt:1.3   Sat 

[PHP-CVS] cvs: php-src(PHP_5_0) /ext/mysqli mysqli.c mysqli_prop.c /ext/mysqli/tests 001.phpt 002.phpt 003.phpt 004.phpt 005.phpt 006.phpt 007.phpt 008.phpt 009.phpt 010.phpt 011.phpt 012.phpt 013.phpt 014.phpt 015.phpt 016.phpt 017.phpt 018.phpt 019.phpt 020.phpt 021.phpt 022.phpt 023.phpt 024.phpt 025.phpt 026.phpt 027.phpt 028.phpt 029.phpt 030.phpt 031.phpt 032.phpt 033.phpt 034.phpt 035.phpt 036.phpt 037.phpt 038.phpt 039.phpt 040.phpt 041.phpt 042.phpt 043.phpt 044.phpt 045.phpt 046.phpt 047.phpt 048.phpt 049.phpt 050.phpt 051.phpt 052.phpt 053.phpt 054.phpt 055.phpt 056.phpt 057.phpt 058.phpt 059.phpt 060.phpt 061.phpt bug29311.phpt bug30967.phpt

2004-12-04 Thread Georg Richter
georg   Sat Dec  4 04:01:34 2004 EDT

  Modified files:  (Branch: PHP_5_0)
/php-src/ext/mysqli mysqli.c mysqli_prop.c 
/php-src/ext/mysqli/tests   001.phpt 002.phpt 003.phpt 004.phpt 
005.phpt 006.phpt 007.phpt 008.phpt 
009.phpt 010.phpt 011.phpt 012.phpt 
013.phpt 014.phpt 015.phpt 016.phpt 
017.phpt 018.phpt 019.phpt 020.phpt 
021.phpt 022.phpt 023.phpt 024.phpt 
025.phpt 026.phpt 027.phpt 028.phpt 
029.phpt 030.phpt 031.phpt 032.phpt 
033.phpt 034.phpt 035.phpt 036.phpt 
037.phpt 038.phpt 039.phpt 040.phpt 
041.phpt 042.phpt 043.phpt 044.phpt 
045.phpt 046.phpt 047.phpt 048.phpt 
049.phpt 050.phpt 051.phpt 052.phpt 
053.phpt 054.phpt 055.phpt 056.phpt 
057.phpt 058.phpt 059.phpt 060.phpt 
061.phpt bug29311.phpt bug30967.phpt 
  Log:
  MFH:
fix for bug #28817 (properties don't work in extended class)
fix for bug #30890 (testsuite)
  
  http://cvs.php.net/diff.php/php-src/ext/mysqli/mysqli.c?r1=1.43.2.7r2=1.43.2.8ty=u
Index: php-src/ext/mysqli/mysqli.c
diff -u php-src/ext/mysqli/mysqli.c:1.43.2.7 
php-src/ext/mysqli/mysqli.c:1.43.2.8
--- php-src/ext/mysqli/mysqli.c:1.43.2.7Fri Dec  3 02:57:39 2004
+++ php-src/ext/mysqli/mysqli.c Sat Dec  4 04:01:33 2004
@@ -15,7 +15,7 @@
   | Author: Georg Richter [EMAIL PROTECTED]|
   +--+
 
-  $Id: mysqli.c,v 1.43.2.7 2004/12/03 07:57:39 georg Exp $ 
+  $Id: mysqli.c,v 1.43.2.8 2004/12/04 09:01:33 georg Exp $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -179,11 +179,6 @@
ret = FAILURE;
obj = (mysqli_object *)zend_objects_get_address(object TSRMLS_CC);
 
-   if (!obj-valid) {
-   retval = EG(uninitialized_zval_ptr);
-   return(retval);
-   }
-
if (member-type != IS_STRING) {
tmp_member = *member;
zval_copy_ctor(tmp_member);
@@ -223,6 +218,7 @@
} else {
std_hnd = zend_get_std_object_handlers();
retval = std_hnd-read_property(object, member, type TSRMLS_CC);
+   retval-refcount = 1;
}
 
if (member == tmp_member) {
http://cvs.php.net/diff.php/php-src/ext/mysqli/mysqli_prop.c?r1=1.14.2.1r2=1.14.2.2ty=u
Index: php-src/ext/mysqli/mysqli_prop.c
diff -u php-src/ext/mysqli/mysqli_prop.c:1.14.2.1 
php-src/ext/mysqli/mysqli_prop.c:1.14.2.2
--- php-src/ext/mysqli/mysqli_prop.c:1.14.2.1   Mon Jul 26 01:45:41 2004
+++ php-src/ext/mysqli/mysqli_prop.cSat Dec  4 04:01:33 2004
@@ -15,7 +15,7 @@
   | Author: Georg Richter [EMAIL PROTECTED]|
   +--+
 
-  $Id: mysqli_prop.c,v 1.14.2.1 2004/07/26 05:45:41 georg Exp $ 
+  $Id: mysqli_prop.c,v 1.14.2.2 2004/12/04 09:01:33 georg Exp $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -29,6 +29,15 @@
 #include ext/standard/info.h
 #include php_mysqli.h
 
+#define CHECK_OBJECT() \
+   if (!obj-valid) { \
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, Property access is 
not allowed yet. Call the default constructor of the object first); \
+   ZVAL_NULL(*retval); \
+   return SUCCESS; \
+   } \
+
+
+
 #define MYSQLI_GET_MYSQL() \
 MYSQL *p = (MYSQL *)((MY_MYSQL *)((MYSQLI_RESOURCE *)(obj-ptr))-ptr)-mysql;
 
@@ -41,9 +50,10 @@
 #define MYSQLI_MAP_PROPERTY_FUNC_LONG( __func, __int_func, __get_type, 
__ret_type)\
 int __func(mysqli_object *obj, zval **retval TSRMLS_DC) \
 {\
+   ALLOC_ZVAL(*retval); \
+   CHECK_OBJECT(); \
__ret_type l;\
__get_type;\
-   ALLOC_ZVAL(*retval);\
if (!p) {\
ZVAL_NULL(*retval);\
} else {\
@@ -63,8 +73,9 @@
 int __func(mysqli_object *obj, zval **retval TSRMLS_DC)\
 {\
char *c;\
+   ALLOC_ZVAL(*retval); \
+   CHECK_OBJECT(); \
__get_type;\
-   ALLOC_ZVAL(*retval);\
if (!p) {\
ZVAL_NULL(*retval);\
} else {\
@@ -96,19 +107,6 @@
 }
 /* }}} */
 
-/* {{{ property link_test_read */
-int link_test_read(mysqli_object *obj, zval **retval TSRMLS_DC)
-{
-   longi;
-   ALLOC_ZVAL(*retval);
-   array_init(*retval);
-
-   for (i=0; i  10; i++)
-   add_index_long(*retval, i, i + 10);
-   return SUCCESS;
-}
-/*i }}} */
-
 /* {{{ property link_connect_errno_read */
 int link_connect_errno_read(mysqli_object *obj, zval **retval TSRMLS_DC)
 {
@@ -147,9 +145,11 @@
 /* {{{ property result_type_read */

[PHP-CVS] cvs: php-src(PHP_5_0) / NEWS

2004-12-04 Thread Georg Richter
georg   Sat Dec  4 04:03:37 2004 EDT

  Modified files:  (Branch: PHP_5_0)
/php-srcNEWS 
  Log:
  fixed bug #30890
  
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1760.2.139r2=1.1760.2.140ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1760.2.139 php-src/NEWS:1.1760.2.140
--- php-src/NEWS:1.1760.2.139   Fri Dec  3 02:57:38 2004
+++ php-src/NEWSSat Dec  4 04:03:36 2004
@@ -9,6 +9,7 @@
 - Fixed potential problems with unserializing invalid serialize data. (Marcus)
 - Fixed bug #30967 (properties in extended mysqli classes don't work). (Georg)
 - Fixed bug #30962 (mssql returns space for NULL columns). (Ilia)
+- Fixed bug #30890 (MySQLi testsuite)
 - Fixed bug #30856 (ReflectionClass::getStaticProperties segfaults). (Marcus)
 - Fixed bug #30832 (! stripped off comments in xml parser). (Rob)
 - Fixed bug #30799 (SoapServer doesn't handle private or protected properties).

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



Re: [PHP-CVS] cvs: php-src /ext/mysqli mysqli.c /ext/mysqli/tests bug30967.phpt

2004-12-04 Thread Georg Richter
Am Fr, den 03.12.2004 schrieb [EMAIL PROTECTED] um 9:31:
 Hi Georg,
 
 Would such a fix (in combination with the fix for #28430) also fix the problem
 described in #28817 (http://bugs.php.net/bug.php?id=28817)?
 
Bug #28817 is fixed in CVS now (mysqli part). I sent a patch to Rob for
ext/dom.

/Georg

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



Re: [PHP-CVS] cvs: php-src /ext/standard var_unserializer.c var_unserializer.re

2004-12-04 Thread Marcus Boerger
Hello Stefan,

  reading the patch twice and checking the code again. Why not simply
replace the index type 'iv' with 'uiv' ?

R: iv ;   - R: uiv ;
r: iv ;   - r: uiv ;

marcus

Wednesday, December 1, 2004, 11:42:00 PM, you wrote:

 sesser  Wed Dec  1 17:42:00 2004 EDT

   Modified files:  
 /php-src/ext/standard   var_unserializer.c var_unserializer.re 
   Log:
   Beware of negative indices
  
  
  
 http://cvs.php.net/diff.php/php-src/ext/standard/var_unserializer.c?r1=1.44r2=1.45ty=u
 Index: php-src/ext/standard/var_unserializer.c
 diff -u php-src/ext/standard/var_unserializer.c:1.44
 php-src/ext/standard/var_unserializer.c:1.45
 --- php-src/ext/standard/var_unserializer.c:1.44Sun Sep 26 17:49:16 
 2004
 +++ php-src/ext/standard/var_unserializer.c Wed Dec  1 17:42:00 2004
 @@ -18,7 +18,7 @@
   
 +--+
  */
 
 -/* $Id: var_unserializer.c,v 1.44 2004/09/26 21:49:16 helly Exp $ */
 +/* $Id: var_unserializer.c,v 1.45 2004/12/01 22:42:00 sesser Exp $ */
 
  #include php.h
  #include ext/standard/php_var.h
 @@ -83,7 +83,7 @@
 
 if (!var_hash) return !SUCCESS;
 
 -   if (id = var_hash-used_slots) return !SUCCESS;
 +   if (id  0 || id = var_hash-used_slots) return !SUCCESS;
 
 *store = var_hash-data[id];
 
 http://cvs.php.net/diff.php/php-src/ext/standard/var_unserializer.re?r1=1.33r2=1.34ty=u
 Index: php-src/ext/standard/var_unserializer.re
 diff -u php-src/ext/standard/var_unserializer.re:1.33
 php-src/ext/standard/var_unserializer.re:1.34
 --- php-src/ext/standard/var_unserializer.re:1.33   Sun Sep 26 17:47:27 
 2004
 +++ php-src/ext/standard/var_unserializer.reWed Dec  1 17:42:00 2004
 @@ -16,7 +16,7 @@
   
 +--+
  */
 
 -/* $Id: var_unserializer.re,v 1.33 2004/09/26 21:47:27 helly Exp $ */
 +/* $Id: var_unserializer.re,v 1.34 2004/12/01 22:42:00 sesser Exp $ */
 
  #include php.h
  #include ext/standard/php_var.h
 @@ -81,7 +81,7 @@
 
 if (!var_hash) return !SUCCESS;
 
 -   if (id = var_hash-used_slots) return !SUCCESS;
 +   if (id  0 || id = var_hash-used_slots) return !SUCCESS;
 
 *store = var_hash-data[id];
 




-- 
Best regards,
 Marcusmailto:[EMAIL PROTECTED]

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



[PHP-CVS] cvs: php-src /ext/dom php_dom.c

2004-12-04 Thread Rob Richards
rrichards   Sat Dec  4 06:39:34 2004 EDT

  Modified files:  
/php-src/ext/domphp_dom.c 
  Log:
  Fixed bug #28817 (Var problem when extending domDocument). (Georg)
  
http://cvs.php.net/diff.php/php-src/ext/dom/php_dom.c?r1=1.64r2=1.65ty=u
Index: php-src/ext/dom/php_dom.c
diff -u php-src/ext/dom/php_dom.c:1.64 php-src/ext/dom/php_dom.c:1.65
--- php-src/ext/dom/php_dom.c:1.64  Thu Oct  7 07:40:20 2004
+++ php-src/ext/dom/php_dom.c   Sat Dec  4 06:39:34 2004
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: php_dom.c,v 1.64 2004/10/07 11:40:20 rrichards Exp $ */
+/* $Id: php_dom.c,v 1.65 2004/12/04 11:39:34 rrichards Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -235,6 +235,7 @@
} else {
std_hnd = zend_get_std_object_handlers();
retval = std_hnd-read_property(object, member, type TSRMLS_CC);
+   retval-refcount = 1;
}
 
if (member == tmp_member) {

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



[PHP-CVS] cvs: php-src /ext/dom/tests bug28817.phpt

2004-12-04 Thread Rob Richards
rrichards   Sat Dec  4 06:40:10 2004 EDT

  Added files: 
/php-src/ext/dom/tests  bug28817.phpt 
  Log:
  add test
  

http://cvs.php.net/co.php/php-src/ext/dom/tests/bug28817.phpt?r=1.1p=1
Index: php-src/ext/dom/tests/bug28817.phpt
+++ php-src/ext/dom/tests/bug28817.phpt
--TEST--
Bug # 28817: (properties in extended class)
--SKIPIF--
?php require_once('skipif.inc'); ?
--FILE--
?php

class z extends domDocument{
/** variable can have name */
public $p_array;
public $p_variable;

function __construct(){
$this-p_array[] = 'bonus';
$this-p_array[] = 'vir';
$this-p_array[] = 'semper';
$this-p_array[] = 'tiro';

$this-p_variable = 'Cessante causa cessat effectus';
}   
}

$z=new z();
var_dump($z-p_array);
var_dump($z-p_variable);
?
--EXPECTF--
array(4) {
  [0]=
  string(5) bonus
  [1]=
  string(3) vir
  [2]=
  string(6) semper
  [3]=
  string(4) tiro
}
string(30) Cessante causa cessat effectus

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



[PHP-CVS] cvs: php-src(PHP_5_0) /ext/dom php_dom.c /ext/dom/tests bug28817.phpt

2004-12-04 Thread Rob Richards
rrichards   Sat Dec  4 06:41:12 2004 EDT

  Added files: (Branch: PHP_5_0)
/php-src/ext/dom/tests  bug28817.phpt 

  Modified files:  
/php-src/ext/domphp_dom.c 
  Log:
  MFH: Fixed bug #28817 (Var problem when extending domDocument). (Georg)
  add test
  
http://cvs.php.net/diff.php/php-src/ext/dom/php_dom.c?r1=1.60.2.2r2=1.60.2.3ty=u
Index: php-src/ext/dom/php_dom.c
diff -u php-src/ext/dom/php_dom.c:1.60.2.2 php-src/ext/dom/php_dom.c:1.60.2.3
--- php-src/ext/dom/php_dom.c:1.60.2.2  Mon Aug 30 11:09:07 2004
+++ php-src/ext/dom/php_dom.c   Sat Dec  4 06:41:12 2004
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: php_dom.c,v 1.60.2.2 2004/08/30 15:09:07 rrichards Exp $ */
+/* $Id: php_dom.c,v 1.60.2.3 2004/12/04 11:41:12 rrichards Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -234,6 +234,7 @@
} else {
std_hnd = zend_get_std_object_handlers();
retval = std_hnd-read_property(object, member, type TSRMLS_CC);
+   retval-refcount = 1;
}
 
if (member == tmp_member) {

http://cvs.php.net/co.php/php-src/ext/dom/tests/bug28817.phpt?r=1.1p=1
Index: php-src/ext/dom/tests/bug28817.phpt
+++ php-src/ext/dom/tests/bug28817.phpt
--TEST--
Bug # 28817: (properties in extended class)
--SKIPIF--
?php require_once('skipif.inc'); ?
--FILE--
?php

class z extends domDocument{
/** variable can have name */
public $p_array;
public $p_variable;

function __construct(){
$this-p_array[] = 'bonus';
$this-p_array[] = 'vir';
$this-p_array[] = 'semper';
$this-p_array[] = 'tiro';

$this-p_variable = 'Cessante causa cessat effectus';
}   
}

$z=new z();
var_dump($z-p_array);
var_dump($z-p_variable);
?
--EXPECTF--
array(4) {
  [0]=
  string(5) bonus
  [1]=
  string(3) vir
  [2]=
  string(6) semper
  [3]=
  string(4) tiro
}
string(30) Cessante causa cessat effectus

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



[PHP-CVS] cvs: php-src(PHP_5_0) / NEWS

2004-12-04 Thread Rob Richards
rrichards   Sat Dec  4 06:41:46 2004 EDT

  Modified files:  (Branch: PHP_5_0)
/php-srcNEWS 
  Log:
  BFN
  
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1760.2.140r2=1.1760.2.141ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1760.2.140 php-src/NEWS:1.1760.2.141
--- php-src/NEWS:1.1760.2.140   Sat Dec  4 04:03:36 2004
+++ php-src/NEWSSat Dec  4 06:41:46 2004
@@ -73,6 +73,7 @@
   (Kamesh Jayachandran).
 - Fixed bug #29385 (Soapserver always uses std class). (David, Dmitry)
 - Fixed bug #29211 (SoapClient doesn't request wsdl through proxy). (Rob)
+- Fixed bug #28817 (Var problem when extending domDocument). (Georg)
 - Fixed bug #28599 (strtotime fails with zero base time). (Derick)
 - Fixed bug #28220 (mb_strwidth() returns wrong width values for some hangul
   characters). (Moriyoshi)

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



Re: [PHP-CVS] cvs: php-src /ext/standard var_unserializer.c var_unserializer.re

2004-12-04 Thread Stefan Esser
Marcus Boerger wrote:
Hello Stefan,
  reading the patch twice and checking the code again. Why not simply
replace the index type 'iv' with 'uiv' ?
R: iv ;   - R: uiv ;
r: iv ;   - r: uiv ;
Because that would not fix anything. Both functions do not check for 
integer overflows when generating the number. So any positive number 
above 2^31 will be negative when casted to int.

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


Re: [PHP-CVS] cvs: php-src /ext/standard var_unserializer.c var_unserializer.re

2004-12-04 Thread Marcus Boerger
Hello Stefan,

Saturday, December 4, 2004, 12:49:19 PM, you wrote:

 Marcus Boerger wrote:
 Hello Stefan,
 
   reading the patch twice and checking the code again. Why not simply
 replace the index type 'iv' with 'uiv' ?
 
 R: iv ;   - R: uiv ;
 r: iv ;   - r: uiv ;

 Because that would not fix anything. Both functions do not check for 
 integer overflows when generating the number. So any positive number 
 above 2^31 will be negative when casted to int.

Ic, in that case iv-uiv is still a good idea and the first check
shouldn't be
if (id == -1 || var_access...
but
if (id  0 || var_access...
. And as a result of those problems we may need to verify the
values generated with parse_iv() and parse_uiv().

regards
marcus




-- 
Best regards,
 Marcusmailto:[EMAIL PROTECTED]

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



[PHP-CVS] cvs: php-src /sapi/apache php_apache.c

2004-12-04 Thread Rasmus Lerdorf
rasmus  Sat Dec  4 08:47:13 2004 EDT

  Modified files:  
/php-src/sapi/apachephp_apache.c 
  Log:
  Fix proto
  
  
http://cvs.php.net/diff.php/php-src/sapi/apache/php_apache.c?r1=1.87r2=1.88ty=u
Index: php-src/sapi/apache/php_apache.c
diff -u php-src/sapi/apache/php_apache.c:1.87 
php-src/sapi/apache/php_apache.c:1.88
--- php-src/sapi/apache/php_apache.c:1.87   Sat Dec  4 02:16:44 2004
+++ php-src/sapi/apache/php_apache.cSat Dec  4 08:47:13 2004
@@ -17,7 +17,7 @@
|  David Sklar [EMAIL PROTECTED] |
+--+
  */
-/* $Id: php_apache.c,v 1.87 2004/12/04 07:16:44 rasmus Exp $ */
+/* $Id: php_apache.c,v 1.88 2004/12/04 13:47:13 rasmus Exp $ */
 
 #include php_apache_http.h
 
@@ -537,7 +537,7 @@
 }
 /* }}} */
 
-/* {{{ proto array apache_reset_timeout(void)
+/* {{{ proto bool apache_reset_timeout(void)
Reset the Apache write timer */
 PHP_FUNCTION(apache_reset_timeout)
 {

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