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

2006-12-17 Thread changelog
changelog   Mon Dec 18 01:30:56 2006 UTC

  Modified files:  
/php-srcChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/php-src/ChangeLog?r1=1.2544r2=1.2545diff_format=u
Index: php-src/ChangeLog
diff -u php-src/ChangeLog:1.2544 php-src/ChangeLog:1.2545
--- php-src/ChangeLog:1.2544Sun Dec 17 01:31:04 2006
+++ php-src/ChangeLog   Mon Dec 18 01:30:55 2006
@@ -1,3 +1,44 @@
+2006-12-17  Marcus Boerger  [EMAIL PROTECTED]
+
+* ext/spl/spl_observer.c
+  ext/spl/tests/observer_003.phpt:
+  - Make this work in unicode mode
+
+2006-12-17  Brian Shire  [EMAIL PROTECTED]
+
+* (PHP_5_2)
+  ext/standard/array.c
+  ext/standard/tests/array/bug30074.phpt
+  ext/standard/tests/array/bug30074.phpt:
+  Fixed bug #30074
+extract with EXTR_REFS was setting EG(unitialized_zval_ptr)-is_ref=1,
+  affecting subsequent usage
+Added test
+
+2006-12-17  Ilia Alshanetsky  [EMAIL PROTECTED]
+
+* main/main.c
+  main/main.c:
+  Fixed compiler warning
+
+* ext/imap/php_imap.c:
+  MFB: Fixed bug #39779 (Enable AUTH PLAIN mechanism in underlaying
+  libc-client).
+
+* (PHP_5_2)
+  NEWS
+  ext/imap/php_imap.c:
+  Fixed bug #39779 (Enable AUTH PLAIN mechanism in underlaying 
libc-client).
+
+2006-12-17  Hannes Magnusson  [EMAIL PROTECTED]
+
+* ext/filter/logical_filters.c:
+  MFB: fix build
+
+* (PHP_5_2)
+  ext/filter/logical_filters.c:
+  Fix build
+
 2006-12-16  Ilia Alshanetsky  [EMAIL PROTECTED]
 
 * ext/filter/logical_filters.c


[PHP-CVS] cvs: php-src /ext/filter logical_filters.c

2006-12-17 Thread Hannes Magnusson
bjori   Sun Dec 17 12:02:19 2006 UTC

  Modified files:  
/php-src/ext/filter logical_filters.c 
  Log:
  MFB: fix build
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/filter/logical_filters.c?r1=1.16r2=1.17diff_format=u
Index: php-src/ext/filter/logical_filters.c
diff -u php-src/ext/filter/logical_filters.c:1.16 
php-src/ext/filter/logical_filters.c:1.17
--- php-src/ext/filter/logical_filters.c:1.16   Sat Dec 16 21:48:21 2006
+++ php-src/ext/filter/logical_filters.cSun Dec 17 12:02:19 2006
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: logical_filters.c,v 1.16 2006/12/16 21:48:21 iliaa Exp $ */
+/* $Id: logical_filters.c,v 1.17 2006/12/17 12:02:19 bjori Exp $ */
 
 #include php_filter.h
 #include filter_private.h
@@ -32,6 +32,11 @@
 # include arpa/inet.h
 #endif
 
+#ifndef INADDR_NONE
+# define INADDR_NONE ((unsigned long int) -1)
+#endif
+
+
 /* {{{ FETCH_LONG_OPTION(var_name, option_name) */
 #define FETCH_LONG_OPTION(var_name, option_name)   
  \
var_name = 0;   
 \
@@ -613,7 +618,7 @@
}
ipv4++;
 
-   if (!_php_filter_validate_ipv4(ipv4, (str + str_len - ipv4), 
ip4elm TSRMLS_CC)) {
+   if (!_php_filter_validate_ipv4(ipv4, (str + str_len - ipv4), 
ip4elm)) {
return 0;
}
 

-- 
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) / NEWS /ext/imap php_imap.c

2006-12-17 Thread Ilia Alshanetsky
iliaa   Sun Dec 17 18:22:53 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/imap   php_imap.c 
/php-srcNEWS 
  Log:
  Fixed bug #39779 (Enable AUTH PLAIN mechanism in underlaying libc-client).
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.208.2.7.2.10r2=1.208.2.7.2.11diff_format=u
Index: php-src/ext/imap/php_imap.c
diff -u php-src/ext/imap/php_imap.c:1.208.2.7.2.10 
php-src/ext/imap/php_imap.c:1.208.2.7.2.11
--- php-src/ext/imap/php_imap.c:1.208.2.7.2.10  Fri Nov 24 10:28:51 2006
+++ php-src/ext/imap/php_imap.c Sun Dec 17 18:22:53 2006
@@ -26,7 +26,7 @@
| PHP 4.0 updates:  Zeev Suraski [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: php_imap.c,v 1.208.2.7.2.10 2006/11/24 10:28:51 tony2001 Exp $ */
+/* $Id: php_imap.c,v 1.208.2.7.2.11 2006/12/17 18:22:53 iliaa Exp $ */
 
 #define IMAP41
 
@@ -471,6 +471,7 @@
 #if HAVE_IMAP_KRB  defined(HAVE_IMAP_AUTH_GSS)
auth_link(auth_gss);   /* link in the gss authenticator */
 #endif
+   auth_link(auth_pla);   /* link in the plain authenticator */
 
 #ifdef HAVE_IMAP_SSL
ssl_onceonlyinit ();
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.432r2=1.2027.2.547.2.433diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.432 php-src/NEWS:1.2027.2.547.2.433
--- php-src/NEWS:1.2027.2.547.2.432 Sat Dec 16 21:48:05 2006
+++ php-src/NEWSSun Dec 17 18:22:53 2006
@@ -67,6 +67,8 @@
 - Fixed bug #39782 (setTime() on a DateTime constructed with a Weekday
   yields incorrect results). (Ilia)
 - Fixed bug #39780 (PNG image with CRC/data error raises fatal error) (Pierre)
+- Fixed bug #39779 (Enable AUTH PLAIN mechanism in underlaying libc-client).
+  (michael dot heimpold at s2000 dot tu-chemnitz dot de, Ilia)
 - Fixed bug #39775 (Indirect modification ... message is not shown). (Dmitry)
 - Fixed bug #39763 (magic quotes are applied twice by ext/filter in
   parse_str()). (Ilia) 

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



[PHP-CVS] cvs: php-src /ext/imap php_imap.c

2006-12-17 Thread Ilia Alshanetsky
iliaa   Sun Dec 17 18:23:10 2006 UTC

  Modified files:  
/php-src/ext/imap   php_imap.c 
  Log:
  MFB: Fixed bug #39779 (Enable AUTH PLAIN mechanism in underlaying
  libc-client).
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.229r2=1.230diff_format=u
Index: php-src/ext/imap/php_imap.c
diff -u php-src/ext/imap/php_imap.c:1.229 php-src/ext/imap/php_imap.c:1.230
--- php-src/ext/imap/php_imap.c:1.229   Fri Nov 24 10:28:26 2006
+++ php-src/ext/imap/php_imap.c Sun Dec 17 18:23:10 2006
@@ -26,7 +26,7 @@
| PHP 4.0 updates:  Zeev Suraski [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: php_imap.c,v 1.229 2006/11/24 10:28:26 tony2001 Exp $ */
+/* $Id: php_imap.c,v 1.230 2006/12/17 18:23:10 iliaa Exp $ */
 
 #define IMAP41
 
@@ -471,6 +471,7 @@
 #if HAVE_IMAP_KRB  defined(HAVE_IMAP_AUTH_GSS)
auth_link(auth_gss);   /* link in the gss authenticator */
 #endif
+   auth_link(auth_pla);   /* link in the plain authenticator */
 
 #ifdef HAVE_IMAP_SSL
ssl_onceonlyinit ();

-- 
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 main.c

2006-12-17 Thread Ilia Alshanetsky
iliaa   Sun Dec 17 18:30:36 2006 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/main   main.c 
  Log:
  Fixed compiler warning
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.21r2=1.640.2.23.2.22diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.640.2.23.2.21 php-src/main/main.c:1.640.2.23.2.22
--- php-src/main/main.c:1.640.2.23.2.21 Mon Dec  4 18:37:15 2006
+++ php-src/main/main.c Sun Dec 17 18:30:36 2006
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.640.2.23.2.21 2006/12/04 18:37:15 stas Exp $ */
+/* $Id: main.c,v 1.640.2.23.2.22 2006/12/17 18:30:36 iliaa Exp $ */
 
 /* {{{ includes
  */
@@ -967,7 +967,7 @@
if (message==ZMSG_MEMORY_LEAK_DETECTED) {
zend_leak_info *t = (zend_leak_info *) 
data;
 
-   snprintf(memory_leak_buf, 512, %s(%d) 
:  Freeing 0x%.8lX (%d bytes), script=%s\n, t-filename, t-lineno, (unsigned 
long)t-addr, t-size, SAFE_FILENAME(SG(request_info).path_translated));
+   snprintf(memory_leak_buf, 512, %s(%d) 
:  Freeing 0x%.8lX (%zu bytes), script=%s\n, t-filename, t-lineno, (unsigned 
long)t-addr, t-size, SAFE_FILENAME(SG(request_info).path_translated));
if (t-orig_filename) {
char relay_buf[512];
 

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



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

2006-12-17 Thread Ilia Alshanetsky
iliaa   Sun Dec 17 18:30:50 2006 UTC

  Modified files:  
/php-src/main   main.c 
  Log:
  Fixed compiler warning
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.712r2=1.713diff_format=u
Index: php-src/main/main.c
diff -u php-src/main/main.c:1.712 php-src/main/main.c:1.713
--- php-src/main/main.c:1.712   Fri Dec  8 19:13:31 2006
+++ php-src/main/main.c Sun Dec 17 18:30:50 2006
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: main.c,v 1.712 2006/12/08 19:13:31 andrei Exp $ */
+/* $Id: main.c,v 1.713 2006/12/17 18:30:50 iliaa Exp $ */
 
 /* {{{ includes
  */
@@ -1076,7 +1076,7 @@
if (message==ZMSG_MEMORY_LEAK_DETECTED) {
zend_leak_info *t = (zend_leak_info *) 
data;
 
-   snprintf(memory_leak_buf, 512, %s(%d) 
:  Freeing 0x%.8lX (%d bytes), script=%s\n, t-filename, t-lineno, (unsigned 
long)t-addr, t-size, SAFE_FILENAME(SG(request_info).path_translated));
+   snprintf(memory_leak_buf, 512, %s(%d) 
:  Freeing 0x%.8lX (%zu bytes), script=%s\n, t-filename, t-lineno, (unsigned 
long)t-addr, t-size, SAFE_FILENAME(SG(request_info).path_translated));
if (t-orig_filename) {
char relay_buf[512];
 

-- 
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/standard array.c /ext/standard/tests/array bug30074.phpt

2006-12-17 Thread Brian Shire
shire   Sun Dec 17 20:09:48 2006 UTC

  Added files: (Branch: PHP_5_2)
/php-src/ext/standard/tests/array   bug30074.phpt 

  Modified files:  
/php-src/ext/standard   array.c 
  Log:
  Fixed bug #30074
extract with EXTR_REFS was setting EG(unitialized_zval_ptr)-is_ref=1, 
affecting subsequent usage
Added test
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.308.2.21.2.20r2=1.308.2.21.2.21diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.308.2.21.2.20 
php-src/ext/standard/array.c:1.308.2.21.2.21
--- php-src/ext/standard/array.c:1.308.2.21.2.20Sun Dec 10 19:43:03 2006
+++ php-src/ext/standard/array.cSun Dec 17 20:09:48 2006
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.308.2.21.2.20 2006/12/10 19:43:03 iliaa Exp $ */
+/* $Id: array.c,v 1.308.2.21.2.21 2006/12/17 20:09:48 shire Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1436,7 +1436,7 @@
 
*orig_var = *entry;
} else {
-   if ((*var_array)-refcount  1) 
{
+   if ((*var_array)-refcount  1 
|| *entry == EG(uninitialized_zval_ptr)) {

SEPARATE_ZVAL_TO_MAKE_IS_REF(entry);
} else {
(*entry)-is_ref = 1;

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/bug30074.phpt?view=markuprev=1.1
Index: php-src/ext/standard/tests/array/bug30074.phpt
+++ php-src/ext/standard/tests/array/bug30074.phpt

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



Re: [PHP-CVS] cvs: php-src /ext/spl spl_observer.c /ext/spl/tests observer_003.phpt

2006-12-17 Thread Marcus Boerger
Hello Andrei,

  thanks for the info. I'll see where the effect comes from then.

best regards
marcus

Saturday, December 16, 2006, 8:10:55 PM, you wrote:

 The only thing added to serializer was the 'S' format. The 'u' format  
 has been there for a while.

 -Andrei


 On Dec 16, 2006, at 5:55 AM, Marcus Boerger wrote:

 helly Sat Dec 16 13:55:14 2006 UTC

   Added files:
 /php-src/ext/spl/testsobserver_003.phpt

   Modified files:
 /php-src/ext/spl  spl_observer.c
   Log:
   - Implement feature request #39836i (SplObjectStorage empty after
 unserialize)
   # Unicode mode currently does not work...looks like funny changes  
 in the
   # unserializer.


 http://cvs.php.net/viewvc.cgi/php-src/ext/spl/spl_observer.c? 
 r1=1.10r2=1.11diff_format=u
 Index: php-src/ext/spl/spl_observer.c
 diff -u php-src/ext/spl/spl_observer.c:1.10 php-src/ext/spl/ 
 spl_observer.c:1.11
 --- php-src/ext/spl/spl_observer.c:1.10   Wed Aug 23 09:31:41 2006
 +++ php-src/ext/spl/spl_observer.cSat Dec 16 13:55:14 2006
 @@ -16,7 +16,7 @@
  
 +- 
 -+
   */

 -/* $Id: spl_observer.c,v 1.10 2006/08/23 09:31:41 bjori Exp $ */
 +/* $Id: spl_observer.c,v 1.11 2006/12/16 13:55:14 helly Exp $ */

  #ifdef HAVE_CONFIG_H
  # include config.h
 @@ -25,6 +25,8 @@
  #include php.h
  #include php_ini.h
  #include ext/standard/info.h
 +#include ext/standard/php_var.h
 +#include ext/standard/php_smart_str.h
  #include zend_interfaces.h
  #include zend_exceptions.h

 @@ -34,6 +36,7 @@
  #include spl_observer.h
  #include spl_iterators.h
  #include spl_array.h
 +#include spl_exceptions.h

  SPL_METHOD(SplObserver, update);
  SPL_METHOD(SplSubject, attach);
 @@ -121,18 +124,8 @@
  }
  /* }}} */

 -/* {{{ proto void SplObjectStorage::attach($obj)
 - Attaches an object to the storage if not yet contained */
 -SPL_METHOD(SplObjectStorage, attach)
 +void spl_object_storage_attach(spl_SplObjectStorage *intern, zval  
 *obj TSRMLS_DC) /* {{{ */
  {
 - zval *obj;
 -
 - spl_SplObjectStorage *intern = (spl_SplObjectStorage*) 
 zend_object_store_get_object(getThis() TSRMLS_CC);
 -
 - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, o, obj)  
 == FAILURE) {
 - return;
 - }
 -
  #if HAVE_PACKED_OBJECT_VALUE
   zend_hash_update(intern-storage, (char*)Z_OBJVAL_P(obj), sizeof 
 (zend_object_value), obj, sizeof(zval*), NULL);  
  #else
 @@ -148,6 +141,20 @@
   obj-refcount++;
  } /* }}} */

 +/* {{{ proto void SplObjectStorage::attach($obj)
 + Attaches an object to the storage if not yet contained */
 +SPL_METHOD(SplObjectStorage, attach)
 +{
 + zval *obj;
 +
 + spl_SplObjectStorage *intern = (spl_SplObjectStorage*) 
 zend_object_store_get_object(getThis() TSRMLS_CC);
 +
 + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, o, obj)  
 == FAILURE) {
 + return;
 + }
 + spl_object_storage_attach(intern, obj TSRMLS_CC);
 +} /* }}} */
 +
  /* {{{ proto void SplObjectStorage::detach($obj)
   Detaches an object from the storage */
  SPL_METHOD(SplObjectStorage, detach)
 @@ -259,11 +266,117 @@
   intern-index++;
  } /* }}} */

 +/* {{{ proto string SplObjectStorage::serialize()
 + */
 +SPL_METHOD(SplObjectStorage, serialize)
 +{
 + spl_SplObjectStorage *intern = (spl_SplObjectStorage*) 
 zend_object_store_get_object(getThis() TSRMLS_CC);
 +
 + zval **entry;
 + HashPosition  pos;
 + php_serialize_data_t var_hash;
 + smart_str buf = {0};
 + long index = 0;
 +
 + PHP_VAR_SERIALIZE_INIT(var_hash);
 +
 + smart_str_appendl(buf, a:, 2);
 + smart_str_append_long(buf, zend_hash_num_elements(intern- 
 storage));
 + smart_str_appendl(buf, :{, 2);
 +
 + zend_hash_internal_pointer_reset_ex(intern-storage, pos);
 +
 + while(zend_hash_has_more_elements_ex(intern-storage, pos) ==  
 SUCCESS) {
 + smart_str_appendl(buf, i:, 2);
 + smart_str_append_long(buf, index++);
 + smart_str_appendc(buf, ';');
 + if (zend_hash_get_current_data_ex(intern-storage, (void**) 
 entry, pos) == FAILURE) {
 + smart_str_free(buf);
 + PHP_VAR_SERIALIZE_DESTROY(var_hash);
 + RETURN_FALSE;
 + }
 + php_var_serialize(buf, entry, var_hash TSRMLS_CC);
 + zend_hash_move_forward_ex(intern-storage, pos);
 + }
 +
 + smart_str_appendc(buf, '}');
 + smart_str_0(buf);
 + PHP_VAR_SERIALIZE_DESTROY(var_hash);
 +
 + if (buf.c) {
 + RETURN_STRINGL(buf.c, buf.len, 0);
 + } else {
 + RETURN_NULL();
 + }
 + 
 +} /* }}} */
 +
 +/* {{{ proto void SplObjectStorage::unserialize(string unserialized)
 + */
 +SPL_METHOD(SplObjectStorage, unserialize)
 +{
 + spl_SplObjectStorage *intern = (spl_SplObjectStorage*) 
 zend_object_store_get_object(getThis() TSRMLS_CC);
 +
 + char *buf;
 + int buf_len;
 +