[PHP-CVS] cvs: php-src /ext/session php_session.h

2009-05-19 Thread Antony Dovgal
tony2001Tue May 19 07:40:51 2009 UTC

  Modified files:  
/php-src/ext/sessionphp_session.h 
  Log:
  fix build
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/session/php_session.h?r1=1.122r2=1.123diff_format=u
Index: php-src/ext/session/php_session.h
diff -u php-src/ext/session/php_session.h:1.122 
php-src/ext/session/php_session.h:1.123
--- php-src/ext/session/php_session.h:1.122 Mon May 18 16:09:51 2009
+++ php-src/ext/session/php_session.h   Tue May 19 07:40:51 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_session.h,v 1.122 2009/05/18 16:09:51 jani Exp $ */
+/* $Id: php_session.h,v 1.123 2009/05/19 07:40:51 tony2001 Exp $ */
 
 #ifndef PHP_SESSION_H
 #define PHP_SESSION_H
@@ -256,7 +256,7 @@
continue;   
\
}   
\
key_length--;   
\
-   if (php_get_session_var(key, key_length, struc 
TSRMLS_CC) == SUCCESS) {\
+   if (php_get_session_var(key.s, key_length, struc 
TSRMLS_CC) == SUCCESS) {  \
code;   
\
}   
\
}   
\



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



Re: [PHP-CVS] cvs: php-src /ext/dba config.m4 dba.c dba_tcadb.c php_tcadb.h

2009-05-19 Thread Kalle Sommer Nielsen
Hi

2009/5/18 Scott MacVicar scott...@php.net:
 scottmac                Mon May 18 20:21:39 2009 UTC

  Added files:
    /php-src/ext/dba    dba_tcadb.c php_tcadb.h

  Modified files:
    /php-src/ext/dba    config.m4 dba.c
  Log:
  Add support for tokyo cabinet, patch from Michael Maclean

NEWS or [DOC] ?



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




-- 
Kalle Sommer Nielsen
ka...@php.net

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



[PHP-CVS] cvs: php-src / NEWS

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 09:14:29 2009 UTC

  Modified files:  
/php-srcNEWS 
  Log:
  DBA entry
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2179r2=1.2180diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2179 php-src/NEWS:1.2180
--- php-src/NEWS:1.2179 Wed Dec 31 14:27:30 2008
+++ php-src/NEWSTue May 19 09:14:28 2009
@@ -32,6 +32,7 @@
   . Added new functions: mhash_keygen_count, mhash_get_keygen_name,
 mhash_keygen_uses_hash, mhash_keygen_uses_salt, mhash_get_keygen_salt_size,
 mhash_keygen.
+- Improved ext/dba; support for Tokyo Cabinet. (Michael Maclean)
 
 - Added runtime JIT auto-globals fetching and caching. (Dmitry, Sara)
 - Added E_STRICT to E_ALL. (Dmitry)



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



Re: [PHP-CVS] cvs: php-src /main php_streams.h /main/streams streams.c

2009-05-19 Thread Kalle Sommer Nielsen
2009/5/17 Arnaud Le Blanc lbarn...@php.net:
 lbarnaud                Sun May 17 16:52:35 2009 UTC

  Modified files:
    /php-src/main       php_streams.h
    /php-src/main/streams       streams.c
  Log:
  un-duplicated code (merged unicode/string variants of stream_copy_to_stream
  and let the compiler optimize specializations)


main\streams\streams.c(517) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(684) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(699) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(703) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(703) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(765) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(779) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(783) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(783) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1039) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1043) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1043) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1204) : warning C4047: 'function' : 'int32_t'
differs in levels of indirection from 'UChar *'
main\streams\streams.c(1204) : warning C4024: 'u_strFindFirst_3_8' :
different types for formal and actual parameter 2
main\streams\streams.c(1232) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1232) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1753) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1758) : warning C4018: '' : signed/unsigned mismatch
main\streams\streams.c(1860) : error C2036: 'void *' : unknown size
NMAKE : fatal error U1077: 'E:\Program Files\Microsoft Visual Studio
9.0\VC\BIN\cl.exe' : return code '0x2'
Stop.

Doesn't build, plus it added a million new warnings


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




-- 
Kalle Sommer Nielsen
ka...@php.net

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



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

2009-05-19 Thread Jani Taskinen
janiTue May 19 09:41:36 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  fix news
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.606r2=1.2027.2.547.2.965.2.607diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.606 
php-src/NEWS:1.2027.2.547.2.965.2.607
--- php-src/NEWS:1.2027.2.547.2.965.2.606   Mon May 18 21:33:38 2009
+++ php-src/NEWSTue May 19 09:41:34 2009
@@ -4,10 +4,12 @@
 - Upgraded bundled sqlite to version 3.6.14. (Scott)
 - Upgraded bundled libmagic to 5.03 in the fileinfo extension. (Scott)
 
-- Added the ability for json_decode() to take a user specified depth. (Scott)
-- Coalesce all the zend_extension_* variables into zend_extension. (Derick)
+- Removed all zend_extension_* php.ini directives. Zend extensions are now
+  always loaded using zend_extension directive. (Derick)
+
+- Changed SQLite3::loadExtension() to be disabled for threaded SAPIs. (Scott)
 
-- Disabled SQLite3::loadExtension for threaded SAPIs. (Scott)
+- Added the ability for json_decode() to take a user specified depth. (Scott)
 
 - Fixed bug #48257 (PharData throws exception with non-phar tar). (Greg)
 - Fixed bug #48227 (NumberFormatter::format leaks memory). (Felipe)



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



[PHP-CVS] cvs: php-src / NEWS

2009-05-19 Thread Jani Taskinen
janiTue May 19 09:47:06 2009 UTC

  Modified files:  
/php-srcNEWS 
  Log:
  fix news
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2181r2=1.2182diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2181 php-src/NEWS:1.2182
--- php-src/NEWS:1.2181 Tue May 19 09:30:17 2009
+++ php-src/NEWSTue May 19 09:47:06 2009
@@ -3,7 +3,7 @@
 ?? ??? 20??, PHP 6.0
 - Unicode support. (Andrei, Dmitry, et al)
 
-- Changed allow_url_fopen/allow_url_include to allow
+- Changed allow_url_fopen and allow_url_include php.ini directives to allow
   per-wrapper enable/disable and runtime tightening. (Sara)
 
 - Removed undocumented and incomplete support for strings in list() operator.
@@ -25,14 +25,15 @@
   operands. (Dmitry)
 - Removed Freetype 1.x and GD 1.x support from GD extension. (Pierre)
 
-- Improved ext/zlib; re-implemented non-file related functionality. (Mike)
-- Improved output layer; see README.NEW-OUTPUT-API for internals. (Mike)
+- Improved ext/zlib: re-implemented non-file related functionality. (Mike)
+- Improved output layer. See README.NEW-OUTPUT-API for internals. (Mike)
 - Improved ext/mhash: (Mike)
   . Added keygen constants.
   . Added new functions: mhash_keygen_count, mhash_get_keygen_name,
 mhash_keygen_uses_hash, mhash_keygen_uses_salt, mhash_get_keygen_salt_size,
 mhash_keygen.
-- Improved ext/dba; support for Tokyo Cabinet. (Michael)
+- Improved ext/dba:
+  . Added support for Tokyo Cabinet. (Michael)
 
 - Added runtime JIT auto-globals fetching and caching. (Dmitry, Sara)
 - Added E_STRICT to E_ALL. (Dmitry)
@@ -43,4 +44,3 @@
 
 - Fixed bug #40325 (Vary: header missing in gzip output handlers). (Mike)
 - Fixed bug #46647 (SplFileObject::fgetcsv segfaults). (Etienne)
-



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



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

2009-05-19 Thread Arnaud Le Blanc
lbarnaudTue May 19 10:04:35 2009 UTC

  Modified files:  
/php-src/main/streams   streams.c 
  Log:
  Fix build
  
  
http://cvs.php.net/viewvc.cgi/php-src/main/streams/streams.c?r1=1.186r2=1.187diff_format=u
Index: php-src/main/streams/streams.c
diff -u php-src/main/streams/streams.c:1.186 
php-src/main/streams/streams.c:1.187
--- php-src/main/streams/streams.c:1.186Sun May 17 16:52:35 2009
+++ php-src/main/streams/streams.c  Tue May 19 10:04:35 2009
@@ -19,7 +19,7 @@
+--+
  */
 
-/* $Id: streams.c,v 1.186 2009/05/17 16:52:35 lbarnaud Exp $ */
+/* $Id: streams.c,v 1.187 2009/05/19 10:04:35 lbarnaud Exp $ */
 
 #define _GNU_SOURCE
 #include php.h
@@ -1857,7 +1857,11 @@
}
 
towrite -= didwrite;
-   writeptr.v += ZBYTES(utype, didwrite);
+   if (utype == IS_UNICODE) {
+   writeptr.u += didwrite;
+   } else {
+   writeptr.s += didwrite;
+   }
}
} else {
break;



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



Re: [PHP-CVS] cvs: php-src /main php_streams.h /main/streams streams.c

2009-05-19 Thread Arnaud Le Blanc
On Tue, 2009-05-19 at 11:24 +0200, Kalle Sommer Nielsen wrote:
 2009/5/17 Arnaud Le Blanc lbarn...@php.net:
  lbarnaudSun May 17 16:52:35 2009 UTC
 
   Modified files:
 /php-src/main   php_streams.h
 /php-src/main/streams   streams.c
   Log:
   un-duplicated code (merged unicode/string variants of stream_copy_to_stream
   and let the compiler optimize specializations)
 
 
 main\streams\streams.c(517) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(684) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(699) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(703) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(703) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(765) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(779) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(783) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(783) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1039) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1043) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1043) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1204) : warning C4047: 'function' : 'int32_t'
 differs in levels of indirection from 'UChar *'
 main\streams\streams.c(1204) : warning C4024: 'u_strFindFirst_3_8' :
 different types for formal and actual parameter 2
 main\streams\streams.c(1232) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1232) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1753) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1758) : warning C4018: '' : signed/unsigned mismatch
 main\streams\streams.c(1860) : error C2036: 'void *' : unknown size
 NMAKE : fatal error U1077: 'E:\Program Files\Microsoft Visual Studio
 9.0\VC\BIN\cl.exe' : return code '0x2'
 Stop.
 
 Doesn't build, plus it added a million new warnings
 

Sorry, fixed the error.
However it does not seems that these warnings are due to this change.

Regards,

Arnaud



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



[PHP-CVS] cvs: php-src /ext/pdo php_pdo_driver.h

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:11:46 2009 UTC

  Modified files:  
/php-src/ext/pdophp_pdo_driver.h 
  Log:
  Fixed compiler warning (HEAD only)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo/php_pdo_driver.h?r1=1.93r2=1.94diff_format=u
Index: php-src/ext/pdo/php_pdo_driver.h
diff -u php-src/ext/pdo/php_pdo_driver.h:1.93 
php-src/ext/pdo/php_pdo_driver.h:1.94
--- php-src/ext/pdo/php_pdo_driver.h:1.93   Tue Mar 10 23:39:28 2009
+++ php-src/ext/pdo/php_pdo_driver.hTue May 19 10:11:46 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: php_pdo_driver.h,v 1.93 2009/03/10 23:39:28 helly Exp $ */
+/* $Id: php_pdo_driver.h,v 1.94 2009/05/19 10:11:46 kalle Exp $ */
 
 #ifndef PHP_PDO_DRIVER_H
 #define PHP_PDO_DRIVER_H
@@ -259,7 +259,7 @@
 
 /* return last insert id.  NULL indicates error condition, otherwise, the 
return value
  * MUST be an emalloc'd NULL terminated string. */
-typedef char *(*pdo_dbh_last_id_func)(pdo_dbh_t *dbh, const char *name, int 
*len TSRMLS_DC);
+typedef char *(*pdo_dbh_last_id_func)(pdo_dbh_t *dbh, const char *name, 
unsigned int *len TSRMLS_DC);
 
 /* fetch error information.  if stmt is not null, fetch information pertaining
  * to the statement, otherwise fetch global error information.  The driver



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



Re: [PHP-CVS] cvs: php-src /main php_streams.h /main/streams streams.c

2009-05-19 Thread Kalle Sommer Nielsen
Hi

2009/5/19 Arnaud Le Blanc lbarn...@php.net:

 Sorry, fixed the error.
 However it does not seems that these warnings are due to this change.

I'll see if I have some time to look into these warnings, I don't
reckon streams.c had this many but its HEAD anyway, and thanks ;)


 Regards,

 Arnaud



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





-- 
Kalle Sommer Nielsen
ka...@php.net

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



[PHP-CVS] cvs: php-src /ext/pdo_dblib config.w32 pdo_dblib.c php_pdo_dblib.h

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:22:10 2009 UTC

  Modified files:  
/php-src/ext/pdo_dblib  config.w32 pdo_dblib.c php_pdo_dblib.h 
  Log:
  Fix --with-pdo-mssql build and add some warnings if header/libs are not found
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/config.w32?r1=1.8r2=1.9diff_format=u
Index: php-src/ext/pdo_dblib/config.w32
diff -u php-src/ext/pdo_dblib/config.w32:1.8 
php-src/ext/pdo_dblib/config.w32:1.9
--- php-src/ext/pdo_dblib/config.w32:1.8Thu May 11 21:48:57 2006
+++ php-src/ext/pdo_dblib/config.w32Tue May 19 10:22:10 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.8 2006/05/11 21:48:57 edink Exp $
+// $Id: config.w32,v 1.9 2009/05/19 10:22:10 kalle Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-dblib, freetds dblib (Sybase, MS-SQL) support for PDO, no);
@@ -13,8 +13,10 @@
{
EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c 
dblib_stmt.c);
ADD_FLAG('CFLAGS_PDO_DBLIB', /D 
PDO_DBLIB_FLAVOUR=\\\freetds\\\);
+   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
+   } else {
+   WARNING(pdo_dblib not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
 }
 
 ARG_WITH(pdo-mssql, Native MS-SQL support for PDO, no);
@@ -64,6 +66,8 @@
PDO_DBLIB_FLAVOUR = MSSQL_ + PDO_DBLIB_FLAVOUR;
}
ADD_FLAG('CFLAGS_PDO_MSSQL', /D PDO_DBLIB_FLAVOUR=\\\ + 
PDO_DBLIB_FLAVOUR + \\\);
+   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
+   } else {
+   WARNING(pdo_mssql not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
 }
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/pdo_dblib.c?r1=1.20r2=1.21diff_format=u
Index: php-src/ext/pdo_dblib/pdo_dblib.c
diff -u php-src/ext/pdo_dblib/pdo_dblib.c:1.20 
php-src/ext/pdo_dblib/pdo_dblib.c:1.21
--- php-src/ext/pdo_dblib/pdo_dblib.c:1.20  Tue Mar 10 23:39:28 2009
+++ php-src/ext/pdo_dblib/pdo_dblib.c   Tue May 19 10:22:10 2009
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: pdo_dblib.c,v 1.20 2009/03/10 23:39:28 helly Exp $ */
+/* $Id: pdo_dblib.c,v 1.21 2009/05/19 10:22:10 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -46,7 +46,11 @@
 };
 #endif
 
+#if PDO_DBLIB_IS_MSSQL
+zend_module_entry pdo_mssql_module_entry = {
+#else
 zend_module_entry pdo_dblib_module_entry = {
+#endif
 #if ZEND_MODULE_API_NO = 20050922
STANDARD_MODULE_HEADER_EX, NULL,
pdo_dblib_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/php_pdo_dblib.h?r1=1.8r2=1.9diff_format=u
Index: php-src/ext/pdo_dblib/php_pdo_dblib.h
diff -u php-src/ext/pdo_dblib/php_pdo_dblib.h:1.8 
php-src/ext/pdo_dblib/php_pdo_dblib.h:1.9
--- php-src/ext/pdo_dblib/php_pdo_dblib.h:1.8   Tue Mar 10 23:39:28 2009
+++ php-src/ext/pdo_dblib/php_pdo_dblib.h   Tue May 19 10:22:10 2009
@@ -17,14 +17,18 @@
   +--+
 */
 
-/* $Id: php_pdo_dblib.h,v 1.8 2009/03/10 23:39:28 helly Exp $ */
+/* $Id: php_pdo_dblib.h,v 1.9 2009/05/19 10:22:10 kalle Exp $ */
 
 #ifndef PHP_PDO_DBLIB_H
 #define PHP_PDO_DBLIB_H
 
-
+#if PDO_DBLIB_IS_MSSQL
+extern zend_module_entry pdo_mssql_module_entry;
+#define phpext_pdo_mssql_ptr pdo_mssql_module_entry
+#else
 extern zend_module_entry pdo_dblib_module_entry;
 #define phpext_pdo_dblib_ptr pdo_dblib_module_entry
+#endif
 
 #ifdef ZTS
 # include TSRM.h



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_dblib config.w32 pdo_dblib.c php_pdo_dblib.h

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:22:25 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_dblib  config.w32 pdo_dblib.c php_pdo_dblib.h 
  Log:
  MFH: Fix --with-pdo-mssql build and add some warnings if header/libs are not 
found
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/config.w32?r1=1.7.4.1r2=1.7.4.1.2.1diff_format=u
Index: php-src/ext/pdo_dblib/config.w32
diff -u php-src/ext/pdo_dblib/config.w32:1.7.4.1 
php-src/ext/pdo_dblib/config.w32:1.7.4.1.2.1
--- php-src/ext/pdo_dblib/config.w32:1.7.4.1Thu May 11 21:43:58 2006
+++ php-src/ext/pdo_dblib/config.w32Tue May 19 10:22:25 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.7.4.1 2006/05/11 21:43:58 edink Exp $
+// $Id: config.w32,v 1.7.4.1.2.1 2009/05/19 10:22:25 kalle Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-dblib, freetds dblib (Sybase, MS-SQL) support for PDO, no);
@@ -13,8 +13,10 @@
{
EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c 
dblib_stmt.c);
ADD_FLAG('CFLAGS_PDO_DBLIB', /D 
PDO_DBLIB_FLAVOUR=\\\freetds\\\);
+   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
+   } else {
+   WARNING(pdo_dblib not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
 }
 
 ARG_WITH(pdo-mssql, Native MS-SQL support for PDO, no);
@@ -64,6 +66,8 @@
PDO_DBLIB_FLAVOUR = MSSQL_ + PDO_DBLIB_FLAVOUR;
}
ADD_FLAG('CFLAGS_PDO_MSSQL', /D PDO_DBLIB_FLAVOUR=\\\ + 
PDO_DBLIB_FLAVOUR + \\\);
+   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
+   } else {
+   WARNING(pdo_mssql not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
 }
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/pdo_dblib.c?r1=1.9.2.6.2.3.2.3r2=1.9.2.6.2.3.2.4diff_format=u
Index: php-src/ext/pdo_dblib/pdo_dblib.c
diff -u php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.3.2.3 
php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.3.2.4
--- php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.3.2.3   Wed Dec 31 11:15:41 2008
+++ php-src/ext/pdo_dblib/pdo_dblib.c   Tue May 19 10:22:25 2009
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: pdo_dblib.c,v 1.9.2.6.2.3.2.3 2008/12/31 11:15:41 sebastian Exp $ */
+/* $Id: pdo_dblib.c,v 1.9.2.6.2.3.2.4 2009/05/19 10:22:25 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -46,7 +46,11 @@
 };
 #endif
 
+#if PDO_DBLIB_IS_MSSQL
+zend_module_entry pdo_mssql_module_entry = {
+#else
 zend_module_entry pdo_dblib_module_entry = {
+#endif
 #if ZEND_MODULE_API_NO = 20050922
STANDARD_MODULE_HEADER_EX, NULL,
pdo_dblib_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/php_pdo_dblib.h?r1=1.2.2.1.2.1.2.3r2=1.2.2.1.2.1.2.4diff_format=u
Index: php-src/ext/pdo_dblib/php_pdo_dblib.h
diff -u php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.1.2.3 
php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.1.2.4
--- php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.1.2.3   Wed Dec 31 
11:15:41 2008
+++ php-src/ext/pdo_dblib/php_pdo_dblib.h   Tue May 19 10:22:25 2009
@@ -17,14 +17,18 @@
   +--+
 */
 
-/* $Id: php_pdo_dblib.h,v 1.2.2.1.2.1.2.3 2008/12/31 11:15:41 sebastian Exp $ 
*/
+/* $Id: php_pdo_dblib.h,v 1.2.2.1.2.1.2.4 2009/05/19 10:22:25 kalle Exp $ */
 
 #ifndef PHP_PDO_DBLIB_H
 #define PHP_PDO_DBLIB_H
 
-
+#if PDO_DBLIB_IS_MSSQL
+extern zend_module_entry pdo_mssql_module_entry;
+#define phpext_pdo_mssql_ptr pdo_mssql_module_entry
+#else
 extern zend_module_entry pdo_dblib_module_entry;
 #define phpext_pdo_dblib_ptr pdo_dblib_module_entry
+#endif
 
 #ifdef ZTS
 # include TSRM.h



-- 
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/pdo_dblib config.w32 pdo_dblib.c php_pdo_dblib.h

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:22:31 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_dblib  config.w32 pdo_dblib.c php_pdo_dblib.h 
  Log:
  MFH: Fix --with-pdo-mssql build and add some warnings if header/libs are not 
found
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/config.w32?r1=1.7.4.1r2=1.7.4.2diff_format=u
Index: php-src/ext/pdo_dblib/config.w32
diff -u php-src/ext/pdo_dblib/config.w32:1.7.4.1 
php-src/ext/pdo_dblib/config.w32:1.7.4.2
--- php-src/ext/pdo_dblib/config.w32:1.7.4.1Thu May 11 21:43:58 2006
+++ php-src/ext/pdo_dblib/config.w32Tue May 19 10:22:31 2009
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.7.4.1 2006/05/11 21:43:58 edink Exp $
+// $Id: config.w32,v 1.7.4.2 2009/05/19 10:22:31 kalle Exp $
 // vim:ft=javascript
 
 ARG_WITH(pdo-dblib, freetds dblib (Sybase, MS-SQL) support for PDO, no);
@@ -13,8 +13,10 @@
{
EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c 
dblib_stmt.c);
ADD_FLAG('CFLAGS_PDO_DBLIB', /D 
PDO_DBLIB_FLAVOUR=\\\freetds\\\);
+   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
+   } else {
+   WARNING(pdo_dblib not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_dblib', 'pdo');
 }
 
 ARG_WITH(pdo-mssql, Native MS-SQL support for PDO, no);
@@ -64,6 +66,8 @@
PDO_DBLIB_FLAVOUR = MSSQL_ + PDO_DBLIB_FLAVOUR;
}
ADD_FLAG('CFLAGS_PDO_MSSQL', /D PDO_DBLIB_FLAVOUR=\\\ + 
PDO_DBLIB_FLAVOUR + \\\);
+   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
+   } else {
+   WARNING(pdo_mssql not enabled, libraries or headers not found)
}
-   ADD_EXTENSION_DEP('pdo_mssql', 'pdo');
 }
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/pdo_dblib.c?r1=1.9.2.6.2.5r2=1.9.2.6.2.6diff_format=u
Index: php-src/ext/pdo_dblib/pdo_dblib.c
diff -u php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.5 
php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.6
--- php-src/ext/pdo_dblib/pdo_dblib.c:1.9.2.6.2.5   Wed Dec 31 11:17:41 2008
+++ php-src/ext/pdo_dblib/pdo_dblib.c   Tue May 19 10:22:31 2009
@@ -17,7 +17,7 @@
   +--+
 */
 
-/* $Id: pdo_dblib.c,v 1.9.2.6.2.5 2008/12/31 11:17:41 sebastian Exp $ */
+/* $Id: pdo_dblib.c,v 1.9.2.6.2.6 2009/05/19 10:22:31 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include config.h
@@ -46,7 +46,11 @@
 };
 #endif
 
+#if PDO_DBLIB_IS_MSSQL
+zend_module_entry pdo_mssql_module_entry = {
+#else
 zend_module_entry pdo_dblib_module_entry = {
+#endif
 #if ZEND_MODULE_API_NO = 20050922
STANDARD_MODULE_HEADER_EX, NULL,
pdo_dblib_deps,
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/php_pdo_dblib.h?r1=1.2.2.1.2.3r2=1.2.2.1.2.4diff_format=u
Index: php-src/ext/pdo_dblib/php_pdo_dblib.h
diff -u php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.3 
php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.4
--- php-src/ext/pdo_dblib/php_pdo_dblib.h:1.2.2.1.2.3   Wed Dec 31 11:17:41 2008
+++ php-src/ext/pdo_dblib/php_pdo_dblib.h   Tue May 19 10:22:31 2009
@@ -17,14 +17,18 @@
   +--+
 */
 
-/* $Id: php_pdo_dblib.h,v 1.2.2.1.2.3 2008/12/31 11:17:41 sebastian Exp $ */
+/* $Id: php_pdo_dblib.h,v 1.2.2.1.2.4 2009/05/19 10:22:31 kalle Exp $ */
 
 #ifndef PHP_PDO_DBLIB_H
 #define PHP_PDO_DBLIB_H
 
-
+#if PDO_DBLIB_IS_MSSQL
+extern zend_module_entry pdo_mssql_module_entry;
+#define phpext_pdo_mssql_ptr pdo_mssql_module_entry
+#else
 extern zend_module_entry pdo_dblib_module_entry;
 #define phpext_pdo_dblib_ptr pdo_dblib_module_entry
+#endif
 
 #ifdef PHP_WIN32
 # define PHP_PDO_DBLIB_API __declspec(dllexport)



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



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

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:23:51 2009 UTC

  Modified files:  
/php-src/ext/exif   exif.c 
  Log:
  Fixed compiler warning
  
http://cvs.php.net/viewvc.cgi/php-src/ext/exif/exif.c?r1=1.211r2=1.212diff_format=u
Index: php-src/ext/exif/exif.c
diff -u php-src/ext/exif/exif.c:1.211 php-src/ext/exif/exif.c:1.212
--- php-src/ext/exif/exif.c:1.211   Tue Mar 10 23:39:17 2009
+++ php-src/ext/exif/exif.c Tue May 19 10:23:51 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: exif.c,v 1.211 2009/03/10 23:39:17 helly Exp $ */
+/* $Id: exif.c,v 1.212 2009/05/19 10:23:51 kalle Exp $ */
 
 /*  ToDos
  *
@@ -138,7 +138,7 @@
 };
 /* }}} */
 
-#define EXIF_VERSION 1.4 $Id: exif.c,v 1.211 2009/03/10 23:39:17 helly Exp $
+#define EXIF_VERSION 1.4 $Id: exif.c,v 1.212 2009/05/19 10:23:51 kalle Exp $
 
 /* {{{ PHP_MINFO_FUNCTION
  */
@@ -3883,7 +3883,7 @@
Reads header data from the JPEG/TIFF image filename and optionally reads 
the internal thumbnails */
 PHP_FUNCTION(exif_read_data)
 {
-   zval **p_name, **p_read_all;
+   zval **p_name;
int i, ac = ZEND_NUM_ARGS(), ret, sections_needed=0;
zend_bool sub_arrays=0, read_thumbnail=0, read_all=0;
image_info_type ImageInfo;
@@ -3927,15 +3927,7 @@
 #endif
}
 
-   if(ac = 5) {
-   convert_to_long_ex(p_read_all);
-   read_all = Z_LVAL_PP(p_read_all);
-   }
-   /* parameters 3,4 will be working in later versions */
-   read_all = 0;   /* just to make function work for 4.2 tree */
-
ret = exif_read_file(ImageInfo, filename, read_thumbnail, read_all 
TSRMLS_CC);
-
sections_str = exif_get_sectionlist(ImageInfo.sections_found TSRMLS_CC);
 
 #ifdef EXIF_DEBUG



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



[PHP-CVS] cvs: php-src /ext/pdo_odbc odbc_stmt.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:25:38 2009 UTC

  Modified files:  
/php-src/ext/pdo_odbc   odbc_stmt.c 
  Log:
  Cast to SQLUSMALLINT
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_odbc/odbc_stmt.c?r1=1.28r2=1.29diff_format=u
Index: php-src/ext/pdo_odbc/odbc_stmt.c
diff -u php-src/ext/pdo_odbc/odbc_stmt.c:1.28 
php-src/ext/pdo_odbc/odbc_stmt.c:1.29
--- php-src/ext/pdo_odbc/odbc_stmt.c:1.28   Tue Mar 10 23:39:31 2009
+++ php-src/ext/pdo_odbc/odbc_stmt.cTue May 19 10:25:38 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: odbc_stmt.c,v 1.28 2009/03/10 23:39:31 helly Exp $ */
+/* $Id: odbc_stmt.c,v 1.29 2009/05/19 10:25:38 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -181,7 +181,7 @@
break;
}
 
-   rc = SQLDescribeParam(S-stmt, 
param-paramno+1, sqltype, precision, scale, nullable);
+   rc = SQLDescribeParam(S-stmt, (SQLUSMALLINT) 
param-paramno+1, sqltype, precision, scale, nullable);
if (rc != SQL_SUCCESS  rc != 
SQL_SUCCESS_WITH_INFO) {
/* MS Access, for instance, doesn't 
support SQLDescribeParam,
 * so we need to guess */
@@ -229,7 +229,7 @@
return 0;
}
 
-   rc = SQLBindParameter(S-stmt, param-paramno+1,
+   rc = SQLBindParameter(S-stmt, (SQLUSMALLINT) 
param-paramno+1,
P-paramtype, ctype, sqltype, 
precision, scale,
P-paramtype == SQL_PARAM_INPUT 
? 
(SQLPOINTER)param :



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_odbc odbc_stmt.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 10:25:53 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_odbc   odbc_stmt.c 
  Log:
  MFH: Cast to SQLUSMALLINT
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_odbc/odbc_stmt.c?r1=1.26.2.2.2.3.2.4r2=1.26.2.2.2.3.2.5diff_format=u
Index: php-src/ext/pdo_odbc/odbc_stmt.c
diff -u php-src/ext/pdo_odbc/odbc_stmt.c:1.26.2.2.2.3.2.4 
php-src/ext/pdo_odbc/odbc_stmt.c:1.26.2.2.2.3.2.5
--- php-src/ext/pdo_odbc/odbc_stmt.c:1.26.2.2.2.3.2.4   Wed Dec 31 11:15:41 2008
+++ php-src/ext/pdo_odbc/odbc_stmt.cTue May 19 10:25:53 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: odbc_stmt.c,v 1.26.2.2.2.3.2.4 2008/12/31 11:15:41 sebastian Exp $ */
+/* $Id: odbc_stmt.c,v 1.26.2.2.2.3.2.5 2009/05/19 10:25:53 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -307,7 +307,7 @@
break;
}
 
-   rc = SQLDescribeParam(S-stmt, 
param-paramno+1, sqltype, precision, scale, nullable);
+   rc = SQLDescribeParam(S-stmt, (SQLUSMALLINT) 
param-paramno+1, sqltype, precision, scale, nullable);
if (rc != SQL_SUCCESS  rc != 
SQL_SUCCESS_WITH_INFO) {
/* MS Access, for instance, doesn't 
support SQLDescribeParam,
 * so we need to guess */
@@ -364,7 +364,7 @@
return 0;
}
 
-   rc = SQLBindParameter(S-stmt, param-paramno+1,
+   rc = SQLBindParameter(S-stmt, (SQLUSMALLINT) 
param-paramno+1,
P-paramtype, ctype, sqltype, 
precision, scale,
P-paramtype == SQL_PARAM_INPUT 
? 
(SQLPOINTER)param :



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



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

2009-05-19 Thread Jani Taskinen
janiTue May 19 11:12:01 2009 UTC

  Modified files:  
/php-src/ext/standard   dns.c 
  Log:
  - Unify the macros
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.c?r1=1.106r2=1.107diff_format=u
Index: php-src/ext/standard/dns.c
diff -u php-src/ext/standard/dns.c:1.106 php-src/ext/standard/dns.c:1.107
--- php-src/ext/standard/dns.c:1.106Tue Mar 10 23:39:39 2009
+++ php-src/ext/standard/dns.c  Tue May 19 11:12:01 2009
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: dns.c,v 1.106 2009/03/10 23:39:39 helly Exp $ */
+/* $Id: dns.c,v 1.107 2009/05/19 11:12:01 jani Exp $ */
 
 /* {{{ includes */
 #include php.h
@@ -278,7 +278,7 @@
 #define PHP_DNS_ALL
(PHP_DNS_A|PHP_DNS_NS|PHP_DNS_CNAME|PHP_DNS_SOA|PHP_DNS_PTR|PHP_DNS_HINFO|PHP_DNS_MX|PHP_DNS_TXT|PHP_DNS_A6|PHP_DNS_SRV|PHP_DNS_NAPTR|PHP_DNS_)
 #endif /* HAVE_DNS_FUNCS || defined(PHP_WIN32) */
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 
 /* {{{ proto bool dns_check_record(string host [, string type]) U
Check DNS records corresponding to a given Internet host name or IP address 
*/
@@ -916,8 +916,7 @@
 }
 /* }}} */
 #endif /* HAVE_DN_SKIPNAME  HAVE_DN_EXPAND */
-#endif /* HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE)) */
-
+#endif /* defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE))) */
 
 #if HAVE_DNS_FUNCS || defined(PHP_WIN32)
 PHP_MINIT_FUNCTION(dns) {



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard dns.c

2009-05-19 Thread Jani Taskinen
janiTue May 19 11:12:20 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard   dns.c 
  Log:
  MFH: Unify macros
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.c?r1=1.70.2.7.2.5.2.20r2=1.70.2.7.2.5.2.21diff_format=u
Index: php-src/ext/standard/dns.c
diff -u php-src/ext/standard/dns.c:1.70.2.7.2.5.2.20 
php-src/ext/standard/dns.c:1.70.2.7.2.5.2.21
--- php-src/ext/standard/dns.c:1.70.2.7.2.5.2.20Mon Jan 12 20:07:28 2009
+++ php-src/ext/standard/dns.c  Tue May 19 11:12:20 2009
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: dns.c,v 1.70.2.7.2.5.2.20 2009/01/12 20:07:28 felipe Exp $ */
+/* $Id: dns.c,v 1.70.2.7.2.5.2.21 2009/05/19 11:12:20 jani Exp $ */
 
 /* {{{ includes */
 #include php.h
@@ -277,7 +277,7 @@
 # define PHP_DNS_ALL
(PHP_DNS_A|PHP_DNS_NS|PHP_DNS_CNAME|PHP_DNS_SOA|PHP_DNS_PTR|PHP_DNS_HINFO|PHP_DNS_MX|PHP_DNS_TXT|PHP_DNS_A6|PHP_DNS_SRV|PHP_DNS_NAPTR|PHP_DNS_)
 #endif /* HAVE_DNS_FUNCS || defined(PHP_WIN32) */
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 
 /* {{{ proto bool dns_check_record(string host [, string type])
Check DNS records corresponding to a given Internet host name or IP address 
*/
@@ -916,8 +916,7 @@
 }
 /* }}} */
 #endif /* HAVE_DN_SKIPNAME  HAVE_DN_EXPAND */
-#endif /* HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE)) */
-
+#endif /* defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE))) */
 
 #if HAVE_DNS_FUNCS || defined(PHP_WIN32)
 



-- 
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 basic_functions.c dns.c dns.h

2009-05-19 Thread Jani Taskinen
janiTue May 19 11:12:33 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   basic_functions.c dns.c dns.h 
  Log:
  MFH: Unify macros
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1=1.725.2.31.2.82r2=1.725.2.31.2.83diff_format=u
Index: php-src/ext/standard/basic_functions.c
diff -u php-src/ext/standard/basic_functions.c:1.725.2.31.2.82 
php-src/ext/standard/basic_functions.c:1.725.2.31.2.83
--- php-src/ext/standard/basic_functions.c:1.725.2.31.2.82  Wed Apr 29 
22:06:28 2009
+++ php-src/ext/standard/basic_functions.c  Tue May 19 11:12:32 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.725.2.31.2.82 2009/04/29 22:06:28 iliaa Exp $ */
+/* $Id: basic_functions.c,v 1.725.2.31.2.83 2009/05/19 11:12:32 jani Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -1113,7 +1113,7 @@
ZEND_ARG_INFO(0, hostname)
 ZEND_END_ARG_INFO()
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 static
 ZEND_BEGIN_ARG_INFO_EX(arginfo_dns_check_record, 0, 0, 1)
ZEND_ARG_INFO(0, host)
@@ -1138,7 +1138,7 @@
ZEND_ARG_INFO(1, weight) /* ARRAY_INFO(1, weight, 1) */
 ZEND_END_ARG_INFO()
 # endif
-#endif /* HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE)) */
+#endif /* defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE))) */
 /* }}} */
 /* {{{ exec.c */
 static
@@ -3443,7 +3443,7 @@
PHP_FE(gethostbyname,   
arginfo_gethostbyname)
PHP_FE(gethostbynamel,  
arginfo_gethostbynamel)
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__) || defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
PHP_FE(dns_check_record,
arginfo_dns_check_record)
PHP_FALIAS(checkdnsrr,  dns_check_record,   
arginfo_dns_check_record)
 # if HAVE_DN_SKIPNAME  HAVE_DN_EXPAND
@@ -4078,7 +4078,7 @@
php_register_url_stream_wrapper(ftp, php_stream_ftp_wrapper 
TSRMLS_CC);
 #endif
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 # if HAVE_DNS_FUNCS
PHP_MINIT(dns)(INIT_FUNC_ARGS_PASSTHRU);
 # endif
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.c?r1=1.70.2.7.2.9r2=1.70.2.7.2.10diff_format=u
Index: php-src/ext/standard/dns.c
diff -u php-src/ext/standard/dns.c:1.70.2.7.2.9 
php-src/ext/standard/dns.c:1.70.2.7.2.10
--- php-src/ext/standard/dns.c:1.70.2.7.2.9 Thu Jan  8 17:20:21 2009
+++ php-src/ext/standard/dns.c  Tue May 19 11:12:33 2009
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: dns.c,v 1.70.2.7.2.9 2009/01/08 17:20:21 felipe Exp $ */
+/* $Id: dns.c,v 1.70.2.7.2.10 2009/05/19 11:12:33 jani Exp $ */
 
 /* {{{ includes */
 #include php.h
@@ -244,7 +244,7 @@
 }
 /* }}} */
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 
 /* {{{ proto int dns_check_record(string host [, string type])
Check DNS records corresponding to a given Internet host name or IP address 
*/
@@ -942,8 +942,7 @@
 }
 /* }}} */
 #endif /* HAVE_DN_SKIPNAME  HAVE_DN_EXPAND */
-
-#endif /* HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32) || 
defined(NETWARE)) */
+#endif /* defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE))) */
 
 /*
  * Local variables:
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.h?r1=1.19.2.1.2.3r2=1.19.2.1.2.4diff_format=u
Index: php-src/ext/standard/dns.h
diff -u php-src/ext/standard/dns.h:1.19.2.1.2.3 
php-src/ext/standard/dns.h:1.19.2.1.2.4
--- php-src/ext/standard/dns.h:1.19.2.1.2.3 Wed Dec 31 11:17:44 2008
+++ php-src/ext/standard/dns.h  Tue May 19 11:12:33 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: dns.h,v 1.19.2.1.2.3 2008/12/31 11:17:44 sebastian Exp $ */
+/* $Id: dns.h,v 1.19.2.1.2.4 2009/05/19 11:12:33 jani Exp $ */
 
 #ifndef DNS_H
 #define DNS_H
@@ -31,7 +31,7 @@
 PHP_FUNCTION(gethostbyname);
 PHP_FUNCTION(gethostbynamel);
 
-#if HAVE_RES_SEARCH  !(defined(__BEOS__)||defined(PHP_WIN32))
+#if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
 
 

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

2009-05-19 Thread Arnaud Le Blanc
lbarnaudTue May 19 11:57:52 2009 UTC

  Modified files:  
/php-src/ext/socketssockets.c 
  Log:
  Fixed bug #48326 (constant MSG_DONTWAIT not defined)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/sockets/sockets.c?r1=1.213r2=1.214diff_format=u
Index: php-src/ext/sockets/sockets.c
diff -u php-src/ext/sockets/sockets.c:1.213 php-src/ext/sockets/sockets.c:1.214
--- php-src/ext/sockets/sockets.c:1.213 Sun May 10 01:00:15 2009
+++ php-src/ext/sockets/sockets.c   Tue May 19 11:57:52 2009
@@ -19,7 +19,7 @@
+--+
  */
 
-/* $Id: sockets.c,v 1.213 2009/05/10 01:00:15 felipe Exp $ */
+/* $Id: sockets.c,v 1.214 2009/05/19 11:57:52 lbarnaud Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -620,6 +620,9 @@
REGISTER_LONG_CONSTANT(SOCK_RDM,  SOCK_RDM,   
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_OOB,   MSG_OOB,
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_WAITALL,   MSG_WAITALL,CONST_CS | 
CONST_PERSISTENT);
+#ifdef MSG_DONTWAIT
+   REGISTER_LONG_CONSTANT(MSG_DONTWAIT,  MSG_DONTWAIT,   CONST_CS | 
CONST_PERSISTENT);
+#endif
REGISTER_LONG_CONSTANT(MSG_PEEK,  MSG_PEEK,   
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_DONTROUTE, MSG_DONTROUTE,  CONST_CS | 
CONST_PERSISTENT);
 #ifdef MSG_EOR



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



Re: [PHP-CVS] cvs: php-src(PHP_5_2) / NEWS /ext/standard file.c

2009-05-19 Thread Antony Dovgal
On 18.05.2009 22:46, Ilia Alshanetsky wrote:
 iliaa Mon May 18 18:46:07 2009 UTC
 
   Modified files:  (Branch: PHP_5_2)
 /php-src/ext/standard file.c 
 /php-src  NEWS 
   Log:
   
   MFB: Fixed bug #48313 (fgetcsv() does not return null for empty rows)

All these tests started to fail:
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation1.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation11.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation14.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation2.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation21.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation6.phpt
/local/qa/5_2.zts/ext/standard/tests/file/fgetcsv_variation7.phpt

-- 
Wbr, 
Antony Dovgal

-- 
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/curl interface.c

2009-05-19 Thread Jani Taskinen
janiTue May 19 13:50:33 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/curl   interface.c 
  Log:
  MFH: Sync with PHP_5_3 the WS/CS and some missing constant fixes
  http://cvs.php.net/viewvc.cgi/php-src/ext/curl/interface.c?r1=1.62.2.14.2.47r2=1.62.2.14.2.48diff_format=u
Index: php-src/ext/curl/interface.c
diff -u php-src/ext/curl/interface.c:1.62.2.14.2.47 
php-src/ext/curl/interface.c:1.62.2.14.2.48
--- php-src/ext/curl/interface.c:1.62.2.14.2.47 Mon May 18 09:11:31 2009
+++ php-src/ext/curl/interface.cTue May 19 13:50:32 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: interface.c,v 1.62.2.14.2.47 2009/05/18 09:11:31 pajoye Exp $ */
+/* $Id: interface.c,v 1.62.2.14.2.48 2009/05/19 13:50:32 jani Exp $ */
 
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
@@ -158,13 +158,14 @@
 #define CAAZ(s, v) add_assoc_zval_ex(return_value, s, sizeof(s), (zval *) v);
 
 #if defined(PHP_WIN32) || defined(__GNUC__)
- #define php_curl_ret(__ret) RETVAL_FALSE; return __ret;
+# define php_curl_ret(__ret) RETVAL_FALSE; return __ret;
 #else
- #define php_curl_ret(__ret) RETVAL_FALSE; return;
+# define php_curl_ret(__ret) RETVAL_FALSE; return;
 #endif
 
-static int php_curl_option_url(php_curl *ch, const char *url, const int len) {
-   CURLcode error=CURLE_OK;
+static int php_curl_option_url(php_curl *ch, const char *url, const int len) 
/* {{{ */
+{
+   CURLcode error = CURLE_OK;
 #if LIBCURL_VERSION_NUM  0x071100
char *copystr = NULL;
 #endif
@@ -201,6 +202,7 @@
 
return (error == CURLE_OK ? 1 : 0);
 }
+/* }}} */
 
 /* {{{ arginfo */
 static
@@ -300,7 +302,6 @@
 ZEND_BEGIN_ARG_INFO(arginfo_curl_multi_close, 0)
ZEND_ARG_INFO(0, mh)
 ZEND_END_ARG_INFO()
-
 /* }}} */
 
 /* {{{ curl_functions[]
@@ -368,6 +369,10 @@
le_curl = zend_register_list_destructors_ex(_php_curl_close, NULL, 
curl, module_number);
le_curl_multi_handle = 
zend_register_list_destructors_ex(_php_curl_multi_close, NULL, curl, 
module_number);
 
+   /* See http://curl.haxx.se/lxr/source/docs/libcurl/symbols-in-versions
+  or curl src/docs/libcurl/symbols-in-versions for a (almost) complete 
list 
+  of options and which version they were introduced */
+
/* Constants for curl_setopt() */
REGISTER_CURL_CONSTANT(CURLOPT_DNS_USE_GLOBAL_CACHE);
REGISTER_CURL_CONSTANT(CURLOPT_DNS_CACHE_TIMEOUT);
@@ -481,14 +486,14 @@
REGISTER_CURL_CONSTANT(CURL_TIMECOND_LASTMOD);
 
 #if LIBCURL_VERSION_NUM  0x070a05 /* CURLOPT_HTTPAUTH is available since curl 
7.10.6 */
-   REGISTER_CURL_CONSTANT(CURLOPT_HTTPAUTH);
-   /* http authentication options */
-   REGISTER_CURL_CONSTANT(CURLAUTH_BASIC);
-   REGISTER_CURL_CONSTANT(CURLAUTH_DIGEST);
-   REGISTER_CURL_CONSTANT(CURLAUTH_GSSNEGOTIATE);
-   REGISTER_CURL_CONSTANT(CURLAUTH_NTLM);
-   REGISTER_CURL_CONSTANT(CURLAUTH_ANY);
-   REGISTER_CURL_CONSTANT(CURLAUTH_ANYSAFE);
+   REGISTER_CURL_CONSTANT(CURLOPT_HTTPAUTH);
+   /* http authentication options */
+   REGISTER_CURL_CONSTANT(CURLAUTH_BASIC);
+   REGISTER_CURL_CONSTANT(CURLAUTH_DIGEST);
+   REGISTER_CURL_CONSTANT(CURLAUTH_GSSNEGOTIATE);
+   REGISTER_CURL_CONSTANT(CURLAUTH_NTLM);
+   REGISTER_CURL_CONSTANT(CURLAUTH_ANY);
+   REGISTER_CURL_CONSTANT(CURLAUTH_ANYSAFE);
 #endif
 
 #if LIBCURL_VERSION_NUM  0x070a06 /* CURLOPT_PROXYAUTH  
CURLOPT_FTP_CREATE_MISSING_DIRS are available since curl 7.10.7 */
@@ -608,8 +613,8 @@
 #if LIBCURL_VERSION_NUM = 0x070b00
REGISTER_CURL_CONSTANT(CURLE_FTP_SSL_FAILED);
 #endif
-
REGISTER_CURL_CONSTANT(CURLPROXY_HTTP);
+   REGISTER_CURL_CONSTANT(CURLPROXY_SOCKS4);
REGISTER_CURL_CONSTANT(CURLPROXY_SOCKS5);
 
REGISTER_CURL_CONSTANT(CURL_NETRC_OPTIONAL);
@@ -1059,7 +1064,7 @@
 PHP_FUNCTION(curl_version)
 {
curl_version_info_data *d;
-   longuversion = CURLVERSION_NOW;
+   long uversion = CURLVERSION_NOW;
 
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, |l, uversion) 
== FAILURE) {
return;
@@ -1123,10 +1128,10 @@
Initialize a cURL session */
 PHP_FUNCTION(curl_init)
 {
-   zval   **url;
-   php_curl*ch;
-   CURL*cp;
-   int  argc = ZEND_NUM_ARGS();
+   php_curl*ch;
+   zval**url;
+   CURL*cp;
+   int argc = ZEND_NUM_ARGS();
 
if (argc  0 || argc  1 || zend_get_parameters_ex(argc, url) == 
FAILURE) {
WRONG_PARAM_COUNT;
@@ -1186,14 +1191,14 @@
Copy a cURL handle along with all of it's preferences */
 PHP_FUNCTION(curl_copy_handle)
 {
-   zval **zid;
-   CURL  *cp;
-   php_curl  *ch;
-   php_curl  *dupch;
+   CURL*cp;
+   zval**zid;
+   php_curl*ch, *dupch;
 
if 

[PHP-CVS] cvs: php-src /ext/curl/tests curl_basic_016.phpt

2009-05-19 Thread Jani Taskinen
janiTue May 19 14:05:29 2009 UTC

  Modified files:  
/php-src/ext/curl/tests curl_basic_016.phpt 
  Log:
  - Fix test: since cURL 7.19.4 CURLINFO_CONTENT_LENGTH_* return -1 if the size 
is unknown
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/curl_basic_016.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/curl/tests/curl_basic_016.phpt
diff -u php-src/ext/curl/tests/curl_basic_016.phpt:1.1 
php-src/ext/curl/tests/curl_basic_016.phpt:1.2
--- php-src/ext/curl/tests/curl_basic_016.phpt:1.1  Sat May 16 16:36:58 2009
+++ php-src/ext/curl/tests/curl_basic_016.phpt  Tue May 19 14:05:29 2009
@@ -48,9 +48,9 @@
   [download_content_length]=
   float(0)
   [upload_content_length]=
-  float(0)
+  float(%f)
   [starttransfer_time]=
-  float(0)
+  float(%f)
   [redirect_time]=
   float(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_3) /ext/curl/tests curl_basic_016.phpt

2009-05-19 Thread Jani Taskinen
janiTue May 19 14:05:40 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/curl/tests curl_basic_016.phpt 
  Log:
  MFH:- Fix test: since cURL 7.19.4 CURLINFO_CONTENT_LENGTH_* return -1 if the 
size is unknown
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/curl_basic_016.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/curl/tests/curl_basic_016.phpt
diff -u php-src/ext/curl/tests/curl_basic_016.phpt:1.1.2.2 
php-src/ext/curl/tests/curl_basic_016.phpt:1.1.2.3
--- php-src/ext/curl/tests/curl_basic_016.phpt:1.1.2.2  Sat May 16 16:37:31 2009
+++ php-src/ext/curl/tests/curl_basic_016.phpt  Tue May 19 14:05:39 2009
@@ -46,9 +46,9 @@
   [speed_upload]=
   float(0)
   [download_content_length]=
-  float(0)
+  float(%f)
   [upload_content_length]=
-  float(0)
+  float(%f)
   [starttransfer_time]=
   float(0)
   [redirect_time]=



-- 
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/curl/tests curl_basic_016.phpt

2009-05-19 Thread Jani Taskinen
janiTue May 19 14:05:49 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/curl/tests curl_basic_016.phpt 
  Log:
  MFH:- Fix test: since cURL 7.19.4 CURLINFO_CONTENT_LENGTH_* return -1 if the 
size is unknown
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/tests/curl_basic_016.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u
Index: php-src/ext/curl/tests/curl_basic_016.phpt
diff -u php-src/ext/curl/tests/curl_basic_016.phpt:1.1.4.2 
php-src/ext/curl/tests/curl_basic_016.phpt:1.1.4.3
--- php-src/ext/curl/tests/curl_basic_016.phpt:1.1.4.2  Sat May 16 16:38:17 2009
+++ php-src/ext/curl/tests/curl_basic_016.phpt  Tue May 19 14:05:49 2009
@@ -46,9 +46,9 @@
   [speed_upload]=
   float(0)
   [download_content_length]=
-  float(0)
+  float(%f)
   [upload_content_length]=
-  float(0)
+  float(%f)
   [starttransfer_time]=
   float(0)
   [redirect_time]=



-- 
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/date php_date.c

2009-05-19 Thread Jani Taskinen
janiTue May 19 15:37:38 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/date   php_date.c 
  Log:
  - Revert bad compile warning fix which causes compile failures with older 
glibc
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.43.2.45.2.68r2=1.43.2.45.2.69diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.43.2.45.2.68 
php-src/ext/date/php_date.c:1.43.2.45.2.69
--- php-src/ext/date/php_date.c:1.43.2.45.2.68  Thu May 14 18:34:27 2009
+++ php-src/ext/date/php_date.c Tue May 19 15:37:38 2009
@@ -16,9 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.43.2.45.2.68 2009/05/14 18:34:27 jani Exp $ */
-
-#define _ISOC9X_SOURCE
+/* $Id: php_date.c,v 1.43.2.45.2.69 2009/05/19 15:37:38 jani Exp $ */
 
 #include php.h
 #include php_streams.h



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/date php_date.c

2009-05-19 Thread Jani Taskinen
janiTue May 19 15:38:07 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/date   php_date.c 
  Log:
  - Revert bad compile warning fix which causes compile failures with older 
glibc
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.43.2.45.2.51.2.75r2=1.43.2.45.2.51.2.76diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.43.2.45.2.51.2.75 
php-src/ext/date/php_date.c:1.43.2.45.2.51.2.76
--- php-src/ext/date/php_date.c:1.43.2.45.2.51.2.75 Wed May 13 18:48:20 2009
+++ php-src/ext/date/php_date.c Tue May 19 15:38:07 2009
@@ -16,9 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.43.2.45.2.51.2.75 2009/05/13 18:48:20 jani Exp $ */
-
-#define _ISOC9X_SOURCE
+/* $Id: php_date.c,v 1.43.2.45.2.51.2.76 2009/05/19 15:38:07 jani Exp $ */
 
 #include php.h
 #include php_streams.h



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



[PHP-CVS] cvs: php-src /ext/date php_date.c

2009-05-19 Thread Jani Taskinen
janiTue May 19 15:38:22 2009 UTC

  Modified files:  
/php-src/ext/date   php_date.c 
  Log:
  - Revert bad compile warning fix which causes compile failures with older 
glibc
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.231r2=1.232diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.231 php-src/ext/date/php_date.c:1.232
--- php-src/ext/date/php_date.c:1.231   Wed May 13 00:45:57 2009
+++ php-src/ext/date/php_date.c Tue May 19 15:38:21 2009
@@ -16,9 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.231 2009/05/13 00:45:57 jani Exp $ */
-
-#define _ISOC9X_SOURCE
+/* $Id: php_date.c,v 1.232 2009/05/19 15:38:21 jani Exp $ */
 
 #include php.h
 #include php_streams.h



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



[PHP-CVS] cvs: php-src /sapi/cgi cgi_main.c fastcgi.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:02:38 2009 UTC

  Modified files:  
/php-src/sapi/cgi   cgi_main.c fastcgi.c 
  Log:
  Fix compiler warnings, and some unicode stuff
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cgi/cgi_main.c?r1=1.377r2=1.378diff_format=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.377 php-src/sapi/cgi/cgi_main.c:1.378
--- php-src/sapi/cgi/cgi_main.c:1.377   Tue Mar 10 23:40:02 2009
+++ php-src/sapi/cgi/cgi_main.c Tue May 19 16:02:38 2009
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.377 2009/03/10 23:40:02 helly Exp $ */
+/* $Id: cgi_main.c,v 1.378 2009/05/19 16:02:38 kalle Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -472,7 +472,8 @@
 
 static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC)
 {
-   int read_bytes=0, tmp_read_bytes;
+   uint read_bytes = 0;
+   int tmp_read_bytes;
 
count_bytes = MIN(count_bytes, (uint) SG(request_info).content_length - 
SG(read_post_bytes));
while (read_bytes  count_bytes) {
http://cvs.php.net/viewvc.cgi/php-src/sapi/cgi/fastcgi.c?r1=1.54r2=1.55diff_format=u
Index: php-src/sapi/cgi/fastcgi.c
diff -u php-src/sapi/cgi/fastcgi.c:1.54 php-src/sapi/cgi/fastcgi.c:1.55
--- php-src/sapi/cgi/fastcgi.c:1.54 Tue Mar 10 23:40:02 2009
+++ php-src/sapi/cgi/fastcgi.c  Tue May 19 16:02:38 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: fastcgi.c,v 1.54 2009/03/10 23:40:02 helly Exp $ */
+/* $Id: fastcgi.c,v 1.55 2009/05/19 16:02:38 kalle Exp $ */
 
 #include php.h
 #include fastcgi.h
@@ -746,7 +746,7 @@
} else if (hdr.type == FCGI_GET_VALUES) {
unsigned char *p = buf + sizeof(fcgi_header);
HashPosition pos;
-   char * str_index;
+   zstr key;
uint str_length;
ulong num_index;
int key_type;
@@ -763,13 +763,13 @@
}
 
zend_hash_internal_pointer_reset_ex(req-env, pos);
-   while ((key_type = zend_hash_get_current_key_ex(req-env, 
str_index, str_length, num_index, 0, pos)) != HASH_KEY_NON_EXISTANT) {
+   while ((key_type = zend_hash_get_current_key_ex(req-env, key, 
str_length, num_index, 0, pos)) != HASH_KEY_NON_EXISTANT) {
int zlen;
zend_hash_move_forward_ex(req-env, pos);
if (key_type != HASH_KEY_IS_STRING) {
continue;
}
-   if (zend_hash_find(fcgi_mgmt_vars, str_index, 
str_length, (void**) value) != SUCCESS) {
+   if (zend_hash_find(fcgi_mgmt_vars, key.s, str_length, 
(void**) value) != SUCCESS) {
continue;
}
--str_length;
@@ -793,7 +793,7 @@
*p++ = (zlen  8)  0xff;
*p++ = zlen  0xff;
}
-   memcpy(p, str_index, str_length);
+   memcpy(p, key.s, str_length);
p += str_length;
memcpy(p, Z_STRVAL_PP(value), zlen);
p += zlen;



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



[PHP-CVS] cvs: php-src(PHP_5_3) /sapi/cgi cgi_main.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:02:56 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/sapi/cgi   cgi_main.c 
  Log:
  MFH: Fix compiler warnings
  
http://cvs.php.net/viewvc.cgi/php-src/sapi/cgi/cgi_main.c?r1=1.267.2.15.2.50.2.37r2=1.267.2.15.2.50.2.38diff_format=u
Index: php-src/sapi/cgi/cgi_main.c
diff -u php-src/sapi/cgi/cgi_main.c:1.267.2.15.2.50.2.37 
php-src/sapi/cgi/cgi_main.c:1.267.2.15.2.50.2.38
--- php-src/sapi/cgi/cgi_main.c:1.267.2.15.2.50.2.37Mon Jan 19 18:17:32 2009
+++ php-src/sapi/cgi/cgi_main.c Tue May 19 16:02:55 2009
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: cgi_main.c,v 1.267.2.15.2.50.2.37 2009/01/19 18:17:32 dsp Exp $ */
+/* $Id: cgi_main.c,v 1.267.2.15.2.50.2.38 2009/05/19 16:02:55 kalle Exp $ */
 
 #include php.h
 #include php_globals.h
@@ -471,7 +471,8 @@
 
 static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC)
 {
-   int read_bytes=0, tmp_read_bytes;
+   uint read_bytes = 0;
+   int tmp_read_bytes;
 
count_bytes = MIN(count_bytes, (uint) SG(request_info).content_length - 
SG(read_post_bytes));
while (read_bytes  count_bytes) {



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



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

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:03:23 2009 UTC

  Modified files:  
/php-src/ext/pgsql  pgsql.c 
  Log:
  Fix compiler warnings, and some unicode stuff
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pgsql/pgsql.c?r1=1.400r2=1.401diff_format=u
Index: php-src/ext/pgsql/pgsql.c
diff -u php-src/ext/pgsql/pgsql.c:1.400 php-src/ext/pgsql/pgsql.c:1.401
--- php-src/ext/pgsql/pgsql.c:1.400 Thu Mar 12 22:53:37 2009
+++ php-src/ext/pgsql/pgsql.c   Tue May 19 16:03:23 2009
@@ -20,7 +20,7 @@
+--+
  */
  
-/* $Id: pgsql.c,v 1.400 2009/03/12 22:53:37 iliaa Exp $ */
+/* $Id: pgsql.c,v 1.401 2009/05/19 16:03:23 kalle Exp $ */
 
 #include stdlib.h
 
@@ -2636,7 +2636,7 @@
zval *result;
PGresult *pgsql_result;
pgsql_result_handle *pg_result;
-   long colno=0;
+   unsigned long colno=0;
int pg_numrows, pg_row;
size_t num_fields;
 
@@ -5095,6 +5095,7 @@
 PHP_PGSQL_API int php_pgsql_convert(PGconn *pg_link, const char *table_name, 
const zval *values, zval *result, ulong opt TSRMLS_DC) 
 {
HashPosition pos;
+   zstr zfield;
char *field = NULL;
uint field_len = -1;
ulong num_idx = -1;
@@ -5122,7 +5123,7 @@
skip_field = 0;
new_val = NULL;

-   if ((key_type = 
zend_hash_get_current_key_ex(Z_ARRVAL_P(values), field, field_len, num_idx, 
0, pos)) == HASH_KEY_NON_EXISTANT) {
+   if ((key_type = 
zend_hash_get_current_key_ex(Z_ARRVAL_P(values), zfield, field_len, num_idx, 
0, pos)) == HASH_KEY_NON_EXISTANT) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, Failed to 
get array key type);
err = 1;
}
@@ -5134,6 +5135,7 @@
php_error_docref(NULL TSRMLS_CC, E_WARNING, Accepts 
only string key for values);
err = 1;
}
+   field = zfield.s;
if (!err  zend_hash_find(Z_ARRVAL_P(meta), field, field_len, 
(void **)def) == FAILURE) {
php_error_docref(NULL TSRMLS_CC, E_NOTICE, Invalid 
field name (%s) in values, field);
err = 1;
@@ -5784,8 +5786,8 @@
 PHP_PGSQL_API int php_pgsql_insert(PGconn *pg_link, const char *table, zval 
*var_array, ulong opt, char **sql TSRMLS_DC)
 {
zval **val, *converted = NULL;
+   zstr zfld;
char buf[256];
-   char *fld;
smart_str querystr = {0};
int key_type, ret = FAILURE;
uint fld_len;
@@ -5819,13 +5821,13 @@
smart_str_appends(querystr,  ();

zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(var_array), pos);
-   while ((key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(var_array), 
fld,
+   while ((key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(var_array), 
zfld,
fld_len, num_idx, 0, pos)) != 
HASH_KEY_NON_EXISTANT) {
if (key_type == HASH_KEY_IS_LONG) {
php_error_docref(NULL TSRMLS_CC, E_NOTICE, Expects 
associative array for values to be inserted);
goto cleanup;
}
-   smart_str_appendl(querystr, fld, fld_len - 1);
+   smart_str_appendl(querystr, zfld.s, fld_len - 1);
smart_str_appendc(querystr, ',');
zend_hash_move_forward_ex(Z_ARRVAL_P(var_array), pos);
}
@@ -5925,24 +5927,24 @@
 static inline int build_assignment_string(smart_str *querystr, HashTable *ht, 
const char *pad, int pad_len TSRMLS_DC)
 {
HashPosition pos;
+   zstr zfld;
uint fld_len;
int key_type;
ulong num_idx;
-   char *fld;
char buf[256];
zval **val;
 
for (zend_hash_internal_pointer_reset_ex(ht, pos);
 zend_hash_get_current_data_ex(ht, (void **)val, pos) == 
SUCCESS;
 zend_hash_move_forward_ex(ht, pos)) {
-key_type = zend_hash_get_current_key_ex(ht, fld, fld_len, 
num_idx, 0, pos);
+key_type = zend_hash_get_current_key_ex(ht, zfld, fld_len, 
num_idx, 0, pos);   
if (key_type == HASH_KEY_IS_LONG) {
php_error_docref(NULL TSRMLS_CC, E_NOTICE, Expects 
associative array for values to be inserted);
return -1;
}
-   smart_str_appendl(querystr, fld, fld_len - 1);
+   smart_str_appendl(querystr, zfld.s, fld_len - 1);
smart_str_appendc(querystr, '=');
-   
+
switch(Z_TYPE_PP(val)) {
case IS_STRING:
smart_str_appendl(querystr, Z_STRVAL_PP(val), 
Z_STRLEN_PP(val));



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pgsql pgsql.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:03:36 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pgsql  pgsql.c 
  Log:
  MFH: Fix compiler warnings
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pgsql/pgsql.c?r1=1.331.2.13.2.24.2.27r2=1.331.2.13.2.24.2.28diff_format=u
Index: php-src/ext/pgsql/pgsql.c
diff -u php-src/ext/pgsql/pgsql.c:1.331.2.13.2.24.2.27 
php-src/ext/pgsql/pgsql.c:1.331.2.13.2.24.2.28
--- php-src/ext/pgsql/pgsql.c:1.331.2.13.2.24.2.27  Thu Mar 12 22:53:16 2009
+++ php-src/ext/pgsql/pgsql.c   Tue May 19 16:03:36 2009
@@ -20,7 +20,7 @@
+--+
  */
  
-/* $Id: pgsql.c,v 1.331.2.13.2.24.2.27 2009/03/12 22:53:16 iliaa Exp $ */
+/* $Id: pgsql.c,v 1.331.2.13.2.24.2.28 2009/05/19 16:03:36 kalle Exp $ */
 
 #include stdlib.h
 
@@ -2650,7 +2650,7 @@
zval *result;
PGresult *pgsql_result;
pgsql_result_handle *pg_result;
-   long colno=0;
+   unsigned long colno=0;
int pg_numrows, pg_row;
size_t num_fields;
 



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/json JSON_parser.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:06:01 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/json   JSON_parser.c 
  Log:
  Cast to unsigned char to prevent compiler warning
  
http://cvs.php.net/viewvc.cgi/php-src/ext/json/JSON_parser.c?r1=1.1.2.12.2.10r2=1.1.2.12.2.11diff_format=u
Index: php-src/ext/json/JSON_parser.c
diff -u php-src/ext/json/JSON_parser.c:1.1.2.12.2.10 
php-src/ext/json/JSON_parser.c:1.1.2.12.2.11
--- php-src/ext/json/JSON_parser.c:1.1.2.12.2.10Thu May 14 22:02:08 2009
+++ php-src/ext/json/JSON_parser.c  Tue May 19 16:06:00 2009
@@ -360,7 +360,7 @@
 | (utf16  0x3ff)) + 0x1;
 buf-len -= 3;
 
-smart_str_appendc(buf, 0xf0 | (utf32  18));
+smart_str_appendc(buf, (unsigned char) (0xf0 | (utf32  18)));
 smart_str_appendc(buf, 0x80 | ((utf32  12)  0x3f));
 smart_str_appendc(buf, 0x80 | ((utf32  6)  0x3f));
 smart_str_appendc(buf, 0x80 | (utf32  0x3f));



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



[PHP-CVS] cvs: php-src /ext/json JSON_parser.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:06:17 2009 UTC

  Modified files:  
/php-src/ext/json   JSON_parser.c 
  Log:
  MFB: Cast to unsigned char to prevent compiler warning
  
http://cvs.php.net/viewvc.cgi/php-src/ext/json/JSON_parser.c?r1=1.26r2=1.27diff_format=u
Index: php-src/ext/json/JSON_parser.c
diff -u php-src/ext/json/JSON_parser.c:1.26 php-src/ext/json/JSON_parser.c:1.27
--- php-src/ext/json/JSON_parser.c:1.26 Thu May 14 00:13:57 2009
+++ php-src/ext/json/JSON_parser.c  Tue May 19 16:06:17 2009
@@ -360,7 +360,7 @@
 | (utf16  0x3ff)) + 0x1;
 buf-len -= 3;
 
-smart_str_appendc(buf, 0xf0 | (utf32  18));
+smart_str_appendc(buf, (unsigned char) (0xf0 | (utf32  18)));
 smart_str_appendc(buf, 0x80 | ((utf32  12)  0x3f));
 smart_str_appendc(buf, 0x80 | ((utf32  6)  0x3f));
 smart_str_appendc(buf, 0x80 | (utf32  0x3f));



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



[PHP-CVS] cvs: php-src /ext/zlib zlib_filter.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:12:04 2009 UTC

  Modified files:  
/php-src/ext/zlib   zlib_filter.c 
  Log:
  Fix compiler warnings (only in HEAD)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/zlib/zlib_filter.c?r1=1.26r2=1.27diff_format=u
Index: php-src/ext/zlib/zlib_filter.c
diff -u php-src/ext/zlib/zlib_filter.c:1.26 php-src/ext/zlib/zlib_filter.c:1.27
--- php-src/ext/zlib/zlib_filter.c:1.26 Tue Mar 10 23:39:52 2009
+++ php-src/ext/zlib/zlib_filter.c  Tue May 19 16:12:04 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: zlib_filter.c,v 1.26 2009/03/10 23:39:52 helly Exp $ */
+/* $Id: zlib_filter.c,v 1.27 2009/05/19 16:12:04 kalle Exp $ */
 
 #include php.h
 #include php_zlib.h
@@ -88,7 +88,7 @@
}
 
bucket = php_stream_bucket_make_writeable(buckets_in-head 
TSRMLS_CC);
-   while (bin  bucket-buflen) {
+   while (bin  (unsigned int) bucket-buflen) {
 
if (data-finished) {
consumed += bucket-buflen;
@@ -220,7 +220,7 @@
 
bucket = php_stream_bucket_make_writeable(bucket TSRMLS_CC);
 
-   while (bin  bucket-buflen) {
+   while (bin  (unsigned int) bucket-buflen) {
desired = bucket-buflen - bin;
if (desired  data-inbuf_len) {
desired = data-inbuf_len;



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 16:14:13 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  Revert faulty warning fix
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.18.2.4.2.3.2.7r2=1.18.2.4.2.3.2.8diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.7 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.8
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.7  Thu May  7 
23:29:54 2009
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 16:14:13 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.18.2.4.2.3.2.7 2009/05/07 23:29:54 mbeccati Exp 
$ */
+/* $Id: sqlite_statement.c,v 1.18.2.4.2.3.2.8 2009/05/19 16:14:13 iliaa Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -265,6 +265,10 @@
case SQLITE3_TEXT:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+   if (*len) {
+   /* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
+   *len--; /* do not remove this, even though it 
generates a warning */
+   }
return 1;

default:



-- 
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/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 16:14:37 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  
  MFB: Revert faulty warning fix
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.18.2.4.2.5r2=1.18.2.4.2.6diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.5 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.6
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.5  Wed Dec 31 
11:17:42 2008
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 16:14:37 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.18.2.4.2.5 2008/12/31 11:17:42 sebastian Exp $ 
*/
+/* $Id: sqlite_statement.c,v 1.18.2.4.2.6 2009/05/19 16:14:37 iliaa Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -244,6 +244,10 @@
default:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+   if (*len) {
+   /* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
+   *len--; /* do not remove this, even though it 
generates a warning */
+   }
return 1;
}
 }



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



[PHP-CVS] cvs: php-src /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 16:14:46 2009 UTC

  Modified files:  
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  
  MFB: Revert faulty warning fix
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.32r2=1.33diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.32 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.33
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.32  Thu May  7 23:04:02 2009
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 16:14:46 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.32 2009/05/07 23:04:02 mbeccati Exp $ */
+/* $Id: sqlite_statement.c,v 1.33 2009/05/19 16:14:46 iliaa Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -265,6 +265,10 @@
case SQLITE3_TEXT:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+   if (*len) {
+   /* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
+   *len--; /* do not remove this, even though it 
generates a warning */
+   }
return 1;

default:



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



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

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:23:36 2009 UTC

  Modified files:  
/php-src/ext/xmlxml.c 
  Log:
  Fix unicode support in utf8_decode()
  
http://cvs.php.net/viewvc.cgi/php-src/ext/xml/xml.c?r1=1.188r2=1.189diff_format=u
Index: php-src/ext/xml/xml.c
diff -u php-src/ext/xml/xml.c:1.188 php-src/ext/xml/xml.c:1.189
--- php-src/ext/xml/xml.c:1.188 Thu Mar 26 20:02:53 2009
+++ php-src/ext/xml/xml.c   Tue May 19 16:23:36 2009
@@ -18,7 +18,7 @@
+--+
  */
 
-/* $Id: xml.c,v 1.188 2009/03/26 20:02:53 felipe Exp $ */
+/* $Id: xml.c,v 1.189 2009/05/19 16:23:36 kalle Exp $ */
 
 #define IS_EXT_MODULE
 
@@ -1780,7 +1780,7 @@
 PHP_FUNCTION(utf8_decode)
 {
XML_Char *decoded;
-   char *data;
+   zstr data;
int len, data_len;
zend_uchar data_type;
 
@@ -1789,9 +1789,9 @@
}
 
if (data_type == IS_UNICODE) {
-   RETURN_UNICODEL(data, data_len, 1);
+   RETURN_UNICODEL(data.u, data_len, 1);
}
-   decoded = xml_utf8_decode(data, data_len, len, NULL);
+   decoded = xml_utf8_decode(data.s, data_len, len, NULL);
 
if (decoded == NULL) {
RETURN_FALSE;



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



[PHP-CVS] cvs: php-src /ext/wddx wddx.c /ext/xmlrpc xmlrpc-epi-php.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 16:32:23 2009 UTC

  Modified files:  
/php-src/ext/wddx   wddx.c 
/php-src/ext/xmlrpc xmlrpc-epi-php.c 
  Log:
  Fix compiler warnings (only in HEAD)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/wddx/wddx.c?r1=1.162r2=1.163diff_format=u
Index: php-src/ext/wddx/wddx.c
diff -u php-src/ext/wddx/wddx.c:1.162 php-src/ext/wddx/wddx.c:1.163
--- php-src/ext/wddx/wddx.c:1.162   Tue Mar 10 23:39:51 2009
+++ php-src/ext/wddx/wddx.c Tue May 19 16:32:22 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: wddx.c,v 1.162 2009/03/10 23:39:51 helly Exp $ */
+/* $Id: wddx.c,v 1.163 2009/05/19 16:32:22 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -294,7 +294,7 @@
 {
zval *retval;
zval **ent;
-   char *key;
+   zstr key;
uint key_length;
char tmp[128];
ulong idx;
@@ -316,11 +316,11 @@
switch (hash_type) {
case HASH_KEY_IS_LONG:
key_length = snprintf(tmp, sizeof(tmp), 
%ld, idx) + 1;
-   key = tmp;
+   key.s = tmp;
/* fallthru */
case HASH_KEY_IS_STRING:
-   php_set_session_var(key, key_length-1, 
*ent, NULL TSRMLS_CC);
-   PS_ADD_VAR(key);
+   php_set_session_var(key.s, 
key_length-1, *ent, NULL TSRMLS_CC);
+   PS_ADD_VAR(key.s);
}
}
}
@@ -455,7 +455,7 @@
 /* OBJECTS_FIXME */
zval **ent, *fname, **varname;
zval *retval = NULL;
-   char *key;
+   zstr key;
ulong idx;
char tmp_buf[WDDX_BUF_LEN];
HashTable *objhash, *sleephash;
@@ -529,7 +529,7 @@
if (zend_hash_get_current_key_ex(objhash, key, 
key_len, idx, 0, NULL) == HASH_KEY_IS_STRING) {
char *class_name, *prop_name;

-   zend_unmangle_property_name(key, key_len-1, 
class_name, prop_name);
+   zend_unmangle_property_name(key.s, key_len-1, 
class_name, prop_name);
php_wddx_serialize_var(packet, *ent, prop_name, 
strlen(prop_name)+1 TSRMLS_CC);
} else {
key_len = snprintf(tmp_buf, sizeof(tmp_buf), 
%ld, idx);
@@ -553,7 +553,7 @@
 static void php_wddx_serialize_array(wddx_packet *packet, zval *arr)
 {
zval **ent;
-   char *key;
+   zstr key;
uint key_len;
int is_struct = 0, ent_type;
ulong idx;
@@ -601,7 +601,7 @@
ent_type = zend_hash_get_current_key_ex(target_hash, 
key, key_len, idx, 0, NULL);
 
if (ent_type == HASH_KEY_IS_STRING) {
-   php_wddx_serialize_var(packet, *ent, key, 
key_len TSRMLS_CC);
+   php_wddx_serialize_var(packet, *ent, key.s, 
key_len TSRMLS_CC);
} else {
key_len = snprintf(tmp_buf, sizeof(tmp_buf), 
%ld, idx);
php_wddx_serialize_var(packet, *ent, tmp_buf, 
key_len TSRMLS_CC);
http://cvs.php.net/viewvc.cgi/php-src/ext/xmlrpc/xmlrpc-epi-php.c?r1=1.71r2=1.72diff_format=u
Index: php-src/ext/xmlrpc/xmlrpc-epi-php.c
diff -u php-src/ext/xmlrpc/xmlrpc-epi-php.c:1.71 
php-src/ext/xmlrpc/xmlrpc-epi-php.c:1.72
--- php-src/ext/xmlrpc/xmlrpc-epi-php.c:1.71Thu May 14 12:30:06 2009
+++ php-src/ext/xmlrpc/xmlrpc-epi-php.c Tue May 19 16:32:22 2009
@@ -51,7 +51,7 @@
+--+
  */
 
-/* $Id: xmlrpc-epi-php.c,v 1.71 2009/05/14 12:30:06 iliaa Exp $ */
+/* $Id: xmlrpc-epi-php.c,v 1.72 2009/05/19 16:32:22 kalle Exp $ */
 
 /**
 * BUGS:   *
@@ -490,7 +490,7 @@
 {
int bArray = 0, bStruct = 0, bMixed = 0;
unsigned long num_index;
-   char* my_key;
+   zstr my_key;
 
zend_hash_internal_pointer_reset(ht);
while (1) {
@@ -558,7 +558,7 @@
{
unsigned long num_index;
zval** pIter;
-   char* my_key;
+   zstr my_key;
HashTable *ht = NULL;
 
ht = HASH_OF(val);
@@ -585,7 +585,7 @@
   

Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Matteo Beccati
Hi Ilia,

 + if (*len) {
 + /* sqlite3.h says the NUL terminator is 
 included in the byte count for TEXT values */
 + *len--; /* do not remove this, even though it 
 generates a warning */
 + }

Would you mind explaining me why the fix was faulty?


Cheers

-- 
Matteo Beccati

OpenX - http://www.openx.org

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



Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
*len is a pointer to an integer, that is being decremented to reduce  
the overall length of the string to remove the NUL terminator. If  
you remove the operation you'll end up with 2 NULs at the end of the  
string.



Ilia Alshanetsky




On 19-May-09, at 12:58 PM, Matteo Beccati wrote:


Hi Ilia,


+   if (*len) {
+/* sqlite3.h says the NUL terminator is included in the byte  
count for TEXT values */
+*len--; /* do not remove this, even though it generates a  
warning */

+   }


Would you mind explaining me why the fix was faulty?


Cheers

--
Matteo Beccati

OpenX - http://www.openx.org

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




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



Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Matteo Beccati
Ilia Alshanetsky ha scritto:
 *len is a pointer to an integer, that is being decremented to reduce the
 overall length of the string to remove the NUL terminator. If you
 remove the operation you'll end up with 2 NULs at the end of the string.

As I said, I coulndn't find any reference to the fact that the NUL
terminator is included in the byte count for TEXT values in sqlite3.h.

I don't want to argue about this, but here's a small test case that
hopefully proves that the code you added back is just useless, as it
doesn't do what you'd expect by reading the comment.

$ cat len.c; gcc -Wall len.c; ./a.out
#include stdio.h
#include assert.h

void decrease_len(int *len)
{
*len--;
}

int main(int argc, char **argv)
{
int len = 10;

decrease_len(len);
assert(len == 9);

return 0;
}

len.c: In function ‘decrease_len’:
len.c:6: warning: value computed is not used
a.out: len.c:14: main: Assertion `len == 9' failed.
Aborted


Cheers

-- 
Matteo Beccati

OpenX - http://www.openx.org

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



[PHP-CVS] cvs: php-src /ext/com_dotnet com_handlers.c com_iterator.c com_persist.c com_saproxy.c com_variant.c com_wrapper.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 17:38:09 2009 UTC

  Modified files:  
/php-src/ext/com_dotnet com_handlers.c com_iterator.c com_persist.c 
com_saproxy.c com_variant.c com_wrapper.c 
  Log:
  Fix compiler warnings and refcount not being in sync with 5.3
  http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/com_handlers.c?r1=1.49r2=1.50diff_format=u
Index: php-src/ext/com_dotnet/com_handlers.c
diff -u php-src/ext/com_dotnet/com_handlers.c:1.49 
php-src/ext/com_dotnet/com_handlers.c:1.50
--- php-src/ext/com_dotnet/com_handlers.c:1.49  Tue Mar 10 23:39:11 2009
+++ php-src/ext/com_dotnet/com_handlers.c   Tue May 19 17:38:08 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: com_handlers.c,v 1.49 2009/03/10 23:39:11 helly Exp $ */
+/* $Id: com_handlers.c,v 1.50 2009/05/19 17:38:08 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -259,7 +259,7 @@
INTERNAL_FUNCTION_PARAM_PASSTHRU);
 }
 
-static union _zend_function *com_method_get(zval **object_ptr, char *name, int 
len TSRMLS_DC)
+static union _zend_function *com_method_get(zval **object_ptr, zstr name, int 
len TSRMLS_DC)
 {
zend_internal_function f, *fptr = NULL;
php_com_dotnet_object *obj;
@@ -273,18 +273,18 @@
return NULL;
}
 
-   if (FAILED(php_com_get_id_of_name(obj, name, len, dummy TSRMLS_CC))) {
+   if (FAILED(php_com_get_id_of_name(obj, name.s, len, dummy TSRMLS_CC))) 
{
return NULL;
}
 
/* check cache */
-   if (obj-method_cache == NULL || FAILURE == 
zend_hash_find(obj-method_cache, name, len, (void**)fptr)) {
+   if (obj-method_cache == NULL || FAILURE == 
zend_hash_find(obj-method_cache, name.s, len, (void**)fptr)) {
f.type = ZEND_OVERLOADED_FUNCTION;
f.num_args = 0;
f.arg_info = NULL;
f.scope = obj-ce;
f.fn_flags = 0;
-   f.function_name.s = estrndup(name, len);
+   f.function_name.s = estrndup(name.s, len);
f.handler = PHP_FN(com_method_handler);
 
fptr = f;
@@ -300,7 +300,7 @@
int i;
 
if (SUCCEEDED(ITypeInfo_GetTypeComp(obj-typeinfo, 
comp))) {
-   olename = php_com_string_to_olestring(name, 
len, obj-code_page TSRMLS_CC);
+   olename = php_com_string_to_olestring(name.s, 
len, obj-code_page TSRMLS_CC);
lhash = LHashValOfNameSys(SYS_WIN32, 
LOCALE_SYSTEM_DEFAULT, olename);
 
if (SUCCEEDED(ITypeComp_Bind(comp, olename, 
lhash, INVOKE_FUNC, TI, kind, bindptr))) {
@@ -348,7 +348,7 @@
zend_hash_init(obj-method_cache, 2, NULL, 
function_dtor, 0);
}
 
-   zend_hash_update(obj-method_cache, name, len, f, 
sizeof(f), (void**)fptr);
+   zend_hash_update(obj-method_cache, name.s, len, f, 
sizeof(f), (void**)fptr);
}
}
 
@@ -364,7 +364,7 @@
return NULL;
 }
 
-static int com_call_method(char *method, INTERNAL_FUNCTION_PARAMETERS)
+static int com_call_method(zstr method, INTERNAL_FUNCTION_PARAMETERS)
 {
zval ***args = NULL;
php_com_dotnet_object *obj;
@@ -387,7 +387,7 @@
 
VariantInit(v);
 
-   if (SUCCESS == php_com_do_invoke_byref(obj, method, -1, 
DISPATCH_METHOD|DISPATCH_PROPERTYGET, v, nargs, args TSRMLS_CC)) {
+   if (SUCCESS == php_com_do_invoke_byref(obj, method.s, -1, 
DISPATCH_METHOD|DISPATCH_PROPERTYGET, v, nargs, args TSRMLS_CC)) {
php_com_zval_from_variant(return_value, v, obj-code_page 
TSRMLS_CC);
ret = SUCCESS;
VariantClear(v);
@@ -434,7 +434,7 @@
}
 }
 
-static zend_class_entry *com_class_entry_get(zval *object TSRMLS_DC)
+static zend_class_entry *com_class_entry_get(const zval *object TSRMLS_DC)
 {
php_com_dotnet_object *obj;
obj = CDNO_FETCH(object);
@@ -442,12 +442,12 @@
return obj-ce;
 }
 
-static int com_class_name_get(zval *object, char **class_name, zend_uint 
*class_name_len, int parent TSRMLS_DC)
+static int com_class_name_get(const zval *object, zstr *class_name, zend_uint 
*class_name_len, int parent TSRMLS_DC)
 {
php_com_dotnet_object *obj;
obj = CDNO_FETCH(object);
 
-   *class_name = estrndup(obj-ce-name.s, obj-ce-name_length);
+   (*class_name).s = estrndup(obj-ce-name.s, obj-ce-name_length);
*class_name_len = obj-ce-name_length;
 
return 0;
@@ -491,7 +491,6 @@
php_com_dotnet_object *obj;
VARIANT v;
VARTYPE vt = VT_EMPTY;
-   zval free_obj;
HRESULT res = S_OK;
 
obj = CDNO_FETCH(readobj);

[PHP-CVS] cvs: php-src(PHP_5_3) /ext/com_dotnet com_handlers.c com_iterator.c com_persist.c com_saproxy.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 17:38:29 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/com_dotnet com_handlers.c com_iterator.c com_persist.c 
com_saproxy.c 
  Log:
  MFH: Fix compiler warnings
  
http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/com_handlers.c?r1=1.30.2.5.2.6.2.5r2=1.30.2.5.2.6.2.6diff_format=u
Index: php-src/ext/com_dotnet/com_handlers.c
diff -u php-src/ext/com_dotnet/com_handlers.c:1.30.2.5.2.6.2.5 
php-src/ext/com_dotnet/com_handlers.c:1.30.2.5.2.6.2.6
--- php-src/ext/com_dotnet/com_handlers.c:1.30.2.5.2.6.2.5  Wed Dec 31 
11:15:35 2008
+++ php-src/ext/com_dotnet/com_handlers.c   Tue May 19 17:38:29 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: com_handlers.c,v 1.30.2.5.2.6.2.5 2008/12/31 11:15:35 sebastian Exp $ 
*/
+/* $Id: com_handlers.c,v 1.30.2.5.2.6.2.6 2009/05/19 17:38:29 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -434,7 +434,7 @@
}
 }
 
-static zend_class_entry *com_class_entry_get(zval *object TSRMLS_DC)
+static zend_class_entry *com_class_entry_get(const zval *object TSRMLS_DC)
 {
php_com_dotnet_object *obj;
obj = CDNO_FETCH(object);
@@ -442,7 +442,7 @@
return obj-ce;
 }
 
-static int com_class_name_get(zval *object, char **class_name, zend_uint 
*class_name_len, int parent TSRMLS_DC)
+static int com_class_name_get(const zval *object, char **class_name, zend_uint 
*class_name_len, int parent TSRMLS_DC)
 {
php_com_dotnet_object *obj;
obj = CDNO_FETCH(object);
http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/com_iterator.c?r1=1.9.2.2.2.2.2.2r2=1.9.2.2.2.2.2.3diff_format=u
Index: php-src/ext/com_dotnet/com_iterator.c
diff -u php-src/ext/com_dotnet/com_iterator.c:1.9.2.2.2.2.2.2 
php-src/ext/com_dotnet/com_iterator.c:1.9.2.2.2.2.2.3
--- php-src/ext/com_dotnet/com_iterator.c:1.9.2.2.2.2.2.2   Wed Dec 31 
11:15:35 2008
+++ php-src/ext/com_dotnet/com_iterator.c   Tue May 19 17:38:29 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: com_iterator.c,v 1.9.2.2.2.2.2.2 2008/12/31 11:15:35 sebastian Exp $ */
+/* $Id: com_iterator.c,v 1.9.2.2.2.2.2.3 2009/05/19 17:38:29 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -111,7 +111,7 @@
}
} else {
/* safe array */
-   if (I-key = I-sa_max) {
+   if (I-key = (ULONG) I-sa_max) {
I-key = (ulong)-1;
return FAILURE;
}
http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/com_persist.c?r1=1.5.2.3.2.2.2.3r2=1.5.2.3.2.2.2.4diff_format=u
Index: php-src/ext/com_dotnet/com_persist.c
diff -u php-src/ext/com_dotnet/com_persist.c:1.5.2.3.2.2.2.3 
php-src/ext/com_dotnet/com_persist.c:1.5.2.3.2.2.2.4
--- php-src/ext/com_dotnet/com_persist.c:1.5.2.3.2.2.2.3Wed Dec 31 
11:15:35 2008
+++ php-src/ext/com_dotnet/com_persist.cTue May 19 17:38:29 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: com_persist.c,v 1.5.2.3.2.2.2.3 2008/12/31 11:15:35 sebastian Exp $ */
+/* $Id: com_persist.c,v 1.5.2.3.2.2.2.4 2009/05/19 17:38:29 kalle Exp $ */
 
 /* Infrastructure for working with persistent COM objects.
  * Implements: IStream* wrapper for PHP streams.
@@ -157,7 +157,7 @@
return STG_E_INVALIDFUNCTION;
}

-   offset = dlibMove.QuadPart;
+   offset = (off_t) dlibMove.QuadPart;
 
ret = php_stream_seek(stm-stream, offset, whence);
 
http://cvs.php.net/viewvc.cgi/php-src/ext/com_dotnet/com_saproxy.c?r1=1.15.2.2.2.3.2.4r2=1.15.2.2.2.3.2.5diff_format=u
Index: php-src/ext/com_dotnet/com_saproxy.c
diff -u php-src/ext/com_dotnet/com_saproxy.c:1.15.2.2.2.3.2.4 
php-src/ext/com_dotnet/com_saproxy.c:1.15.2.2.2.3.2.5
--- php-src/ext/com_dotnet/com_saproxy.c:1.15.2.2.2.3.2.4   Wed Dec 31 
11:15:35 2008
+++ php-src/ext/com_dotnet/com_saproxy.cTue May 19 17:38:29 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: com_saproxy.c,v 1.15.2.2.2.3.2.4 2008/12/31 11:15:35 sebastian Exp $ */
+/* $Id: com_saproxy.c,v 1.15.2.2.2.3.2.5 2009/05/19 17:38:29 kalle Exp $ */
 
 /* This module implements a SafeArray proxy which is used internally
  * by the engine when resolving multi-dimensional array accesses on
@@ -92,10 +92,9 @@
 {
php_com_saproxy *proxy = SA_FETCH(object);
zval *return_value;
-   UINT dims;
+   UINT dims, i;
SAFEARRAY *sa;
LONG ubound, lbound;
-   int i;
HRESULT res;

MAKE_STD_ZVAL(return_value);
@@ -110,7 +109,7 @@
 
args = safe_emalloc(proxy-dimensions + 1, sizeof(zval *), 0);
 
-   for (i = 1; i  proxy-dimensions; i++) {
+   for (i = 1; i  (UINT) 

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

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 17:46:56 2009 UTC

  Modified files:  
/php-src/ext/mcrypt mcrypt.c 
  Log:
  Fix compiler warning
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mcrypt/mcrypt.c?r1=1.121r2=1.122diff_format=u
Index: php-src/ext/mcrypt/mcrypt.c
diff -u php-src/ext/mcrypt/mcrypt.c:1.121 php-src/ext/mcrypt/mcrypt.c:1.122
--- php-src/ext/mcrypt/mcrypt.c:1.121   Tue Mar 10 23:39:27 2009
+++ php-src/ext/mcrypt/mcrypt.c Tue May 19 17:46:56 2009
@@ -16,7 +16,7 @@
|  Derick Rethans der...@derickrethans.nl|
+--+
  */
-/* $Id: mcrypt.c,v 1.121 2009/03/10 23:39:27 helly Exp $ */
+/* $Id: mcrypt.c,v 1.122 2009/05/19 17:46:56 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1226,7 +1226,7 @@
case PHP_MCRYPT_IV_SOURCE_RAND:
*iv_len = size;
while (size) {
-   (*iv_str)[--size] = 255.0 * 
php_rand(TSRMLS_C) / RAND_MAX;
+   (*iv_str)[--size] = (char) (255.0 * 
php_rand(TSRMLS_C) / RAND_MAX);
}
break;
}



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/mcrypt mcrypt.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 17:47:06 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/mcrypt mcrypt.c 
  Log:
  MFH: Fixed compiler warning
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mcrypt/mcrypt.c?r1=1.91.2.3.2.11.2.16r2=1.91.2.3.2.11.2.17diff_format=u
Index: php-src/ext/mcrypt/mcrypt.c
diff -u php-src/ext/mcrypt/mcrypt.c:1.91.2.3.2.11.2.16 
php-src/ext/mcrypt/mcrypt.c:1.91.2.3.2.11.2.17
--- php-src/ext/mcrypt/mcrypt.c:1.91.2.3.2.11.2.16  Wed Dec 31 11:15:38 2008
+++ php-src/ext/mcrypt/mcrypt.c Tue May 19 17:47:06 2009
@@ -16,7 +16,7 @@
|  Derick Rethans der...@derickrethans.nl|
+--+
  */
-/* $Id: mcrypt.c,v 1.91.2.3.2.11.2.16 2008/12/31 11:15:38 sebastian Exp $ */
+/* $Id: mcrypt.c,v 1.91.2.3.2.11.2.17 2009/05/19 17:47:06 kalle Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -1424,7 +1424,7 @@
} else {
n = size;
while (size) {
-   iv[--size] = 255.0 * php_rand(TSRMLS_C) / RAND_MAX;
+   iv[--size] = (char) (255.0 * php_rand(TSRMLS_C) / 
RAND_MAX);
}
}
RETURN_STRINGL(iv, n, 0);



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



[PHP-CVS] cvs: php-src /ext/curl interface.c streams.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 18:08:13 2009 UTC

  Modified files:  
/php-src/ext/curl   interface.c streams.c 
  Log:
  Fixed compiler warnings
  
  # Is it intended that curl_progress should cast to long rather than keeping 
the 
  # double? Or doesn't it matter?
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/interface.c?r1=1.163r2=1.164diff_format=u
Index: php-src/ext/curl/interface.c
diff -u php-src/ext/curl/interface.c:1.163 php-src/ext/curl/interface.c:1.164
--- php-src/ext/curl/interface.c:1.163  Mon May 18 12:50:44 2009
+++ php-src/ext/curl/interface.cTue May 19 18:08:13 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: interface.c,v 1.163 2009/05/18 12:50:44 jani Exp $ */
+/* $Id: interface.c,v 1.164 2009/05/19 18:08:13 kalle Exp $ */
 
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
@@ -967,10 +967,10 @@
MAKE_STD_ZVAL(zultotal);
MAKE_STD_ZVAL(zulnow);
 
-   ZVAL_LONG(zdltotal, dltotal);
-   ZVAL_LONG(zdlnow, dlnow);
-   ZVAL_LONG(zultotal, ultotal);
-   ZVAL_LONG(zulnow, ulnow);
+   ZVAL_LONG(zdltotal, (long) dltotal);
+   ZVAL_LONG(zdlnow, (long) dlnow);
+   ZVAL_LONG(zultotal, (long) ultotal);
+   ZVAL_LONG(zulnow, (long) ulnow);
 
argv[0] = zdltotal;
argv[1] = zdlnow;
@@ -1071,7 +1071,7 @@
 #endif
} else if (retval_ptr) {
if (Z_TYPE_P(retval_ptr) == IS_STRING) {
-   length = MIN(size * nmemb, 
Z_STRLEN_P(retval_ptr));
+   length = MIN((int) (size * nmemb), 
Z_STRLEN_P(retval_ptr));
memcpy(data, Z_STRVAL_P(retval_ptr), 
length);
}
zval_ptr_dtor(retval_ptr);
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/streams.c?r1=1.33r2=1.34diff_format=u
Index: php-src/ext/curl/streams.c
diff -u php-src/ext/curl/streams.c:1.33 php-src/ext/curl/streams.c:1.34
--- php-src/ext/curl/streams.c:1.33 Tue May  5 00:30:40 2009
+++ php-src/ext/curl/streams.c  Tue May 19 18:08:13 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: streams.c,v 1.33 2009/05/05 00:30:40 jani Exp $ */
+/* $Id: streams.c,v 1.34 2009/05/19 18:08:13 kalle Exp $ */
 
 /* This file implements cURL based wrappers.
  * NOTE: If you are implementing your own streams that are intended to
@@ -132,7 +132,7 @@
 
/* our notification system only works in a single direction; we should 
detect which
 * direction is important and use the correct values in this call */
-   php_stream_notify_progress(stream-context, dlnow, dltotal);
+   php_stream_notify_progress(stream-context, (size_t) dlnow, (size_t) 
dltotal);
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_3) /ext/curl interface.c streams.c

2009-05-19 Thread Kalle Sommer Nielsen
kalle   Tue May 19 18:08:58 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/curl   interface.c streams.c 
  Log:
  MFH: Fixed compiler warnings
  
  # (see previous commit message)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/interface.c?r1=1.62.2.14.2.27.2.46r2=1.62.2.14.2.27.2.47diff_format=u
Index: php-src/ext/curl/interface.c
diff -u php-src/ext/curl/interface.c:1.62.2.14.2.27.2.46 
php-src/ext/curl/interface.c:1.62.2.14.2.27.2.47
--- php-src/ext/curl/interface.c:1.62.2.14.2.27.2.46Mon May 18 12:51:05 2009
+++ php-src/ext/curl/interface.cTue May 19 18:08:57 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: interface.c,v 1.62.2.14.2.27.2.46 2009/05/18 12:51:05 jani Exp $ */
+/* $Id: interface.c,v 1.62.2.14.2.27.2.47 2009/05/19 18:08:57 kalle Exp $ */
 
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
@@ -967,10 +967,10 @@
MAKE_STD_ZVAL(zultotal);
MAKE_STD_ZVAL(zulnow);
 
-   ZVAL_LONG(zdltotal, dltotal);
-   ZVAL_LONG(zdlnow, dlnow);
-   ZVAL_LONG(zultotal, ultotal);
-   ZVAL_LONG(zulnow, ulnow);
+   ZVAL_LONG(zdltotal, (long) dltotal);
+   ZVAL_LONG(zdlnow, (long) dlnow);
+   ZVAL_LONG(zultotal, (long) ultotal);
+   ZVAL_LONG(zulnow, (long) ulnow);
 
argv[0] = zdltotal;
argv[1] = zdlnow;
@@ -1071,7 +1071,7 @@
 #endif
} else if (retval_ptr) {
if (Z_TYPE_P(retval_ptr) == IS_STRING) {
-   length = MIN(size * nmemb, 
Z_STRLEN_P(retval_ptr));
+   length = MIN((int) (size * nmemb), 
Z_STRLEN_P(retval_ptr));
memcpy(data, Z_STRVAL_P(retval_ptr), 
length);
}
zval_ptr_dtor(retval_ptr);
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/streams.c?r1=1.14.2.2.2.11.2.5r2=1.14.2.2.2.11.2.6diff_format=u
Index: php-src/ext/curl/streams.c
diff -u php-src/ext/curl/streams.c:1.14.2.2.2.11.2.5 
php-src/ext/curl/streams.c:1.14.2.2.2.11.2.6
--- php-src/ext/curl/streams.c:1.14.2.2.2.11.2.5Tue May  5 00:31:56 2009
+++ php-src/ext/curl/streams.c  Tue May 19 18:08:57 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: streams.c,v 1.14.2.2.2.11.2.5 2009/05/05 00:31:56 jani Exp $ */
+/* $Id: streams.c,v 1.14.2.2.2.11.2.6 2009/05/19 18:08:57 kalle Exp $ */
 
 /* This file implements cURL based wrappers.
  * NOTE: If you are implementing your own streams that are intended to
@@ -132,7 +132,7 @@
 
/* our notification system only works in a single direction; we should 
detect which
 * direction is important and use the correct values in this call */
-   php_stream_notify_progress(stream-context, dlnow, dltotal);
+   php_stream_notify_progress(stream-context, (size_t) dlnow, (size_t) 
dltotal);
return 0;
 }
 



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



Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky

The code should be (*len)--; then the result is as desired, I'll adjust.


Ilia Alshanetsky




On 19-May-09, at 1:33 PM, Matteo Beccati wrote:


Ilia Alshanetsky ha scritto:
*len is a pointer to an integer, that is being decremented to  
reduce the

overall length of the string to remove the NUL terminator. If you
remove the operation you'll end up with 2 NULs at the end of the  
string.


As I said, I coulndn't find any reference to the fact that the NUL
terminator is included in the byte count for TEXT values in  
sqlite3.h.


I don't want to argue about this, but here's a small test case that
hopefully proves that the code you added back is just useless, as it
doesn't do what you'd expect by reading the comment.

$ cat len.c; gcc -Wall len.c; ./a.out
#include stdio.h
#include assert.h

void decrease_len(int *len)
{
   *len--;
}

int main(int argc, char **argv)
{
   int len = 10;

   decrease_len(len);
   assert(len == 9);

   return 0;
}

len.c: In function ‘decrease_len’:
len.c:6: warning: value computed is not used
a.out: len.c:14: main: Assertion `len == 9' failed.
Aborted


Cheers

--
Matteo Beccati

OpenX - http://www.openx.org



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



[PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/sqlite3/libsqlite sqlite3.c sqlite3.h sqlite3ext.h

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 18:33:02 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
/php-src/ext/sqlite3/libsqlite  sqlite3.c sqlite3.h sqlite3ext.h 
  Log:
  Upgraded to 3.6.14.1
  
  http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.607r2=1.2027.2.547.2.965.2.608diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.607 
php-src/NEWS:1.2027.2.547.2.965.2.608
--- php-src/NEWS:1.2027.2.547.2.965.2.607   Tue May 19 09:41:34 2009
+++ php-src/NEWSTue May 19 18:32:25 2009
@@ -1,7 +1,7 @@
 PHPNEWS
 |||
 ?? ??? 2009, PHP 5.3.0 RC 3
-- Upgraded bundled sqlite to version 3.6.14. (Scott)
+- Upgraded bundled sqlite to version 3.6.14.1. (Ilia)
 - Upgraded bundled libmagic to 5.03 in the fileinfo extension. (Scott)
 
 - Removed all zend_extension_* php.ini directives. Zend extensions are now
http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/libsqlite/sqlite3.c?r1=1.1.2.21r2=1.1.2.22diff_format=u
Index: php-src/ext/sqlite3/libsqlite/sqlite3.c
diff -u php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.21 
php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.22
--- php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.21Thu May  7 12:39:26 2009
+++ php-src/ext/sqlite3/libsqlite/sqlite3.c Tue May 19 18:32:25 2009
@@ -4,7 +4,7 @@
 
 /**
 ** This file is an amalgamation of many separate C source files from SQLite
-** version 3.6.14.  By combining all the individual C code files into this 
+** version 3.6.14.1.  By combining all the individual C code files into this 
 ** single large file, the entire code can be compiled as a one translation
 ** unit.  This allows many compilers to do optimizations that would not be
 ** possible if the files were compiled separately.  Performance improvements
@@ -21,7 +21,7 @@
 ** is also in a separate file.  This file contains only code for the core
 ** SQLite library.
 **
-** This amalgamation was generated on 2009-05-07 01:56:00 UTC.
+** This amalgamation was generated on 2009-05-18 18:33:54 UTC.
 */
 #define SQLITE_CORE 1
 #define SQLITE_AMALGAMATION 1
@@ -45,7 +45,7 @@
 *
 ** Internal interface definitions for SQLite.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 #ifndef _SQLITEINT_H_
 #define _SQLITEINT_H_
@@ -74,7 +74,7 @@
 ** 
 ** This file defines various limits of what SQLite can process.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 
 /*
@@ -532,7 +532,7 @@
 ** the version number) and changes its name to sqlite3.h as
 ** part of the build process.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 #ifndef _SQLITE3_H_
 #define _SQLITE3_H_
@@ -601,7 +601,7 @@
 **
 ** Requirements: [H10011] [H10014]
 */
-#define SQLITE_VERSION 3.6.14
+#define SQLITE_VERSION 3.6.14.1
 #define SQLITE_VERSION_NUMBER  3006014
 
 /*
@@ -6052,7 +6052,7 @@
 ** This is the header file for the generic hash-table implemenation
 ** used in SQLite.
 **
-** $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 #ifndef _SQLITE_HASH_H_
 #define _SQLITE_HASH_H_
@@ -6635,7 +6635,7 @@
 ** subsystem.  See comments in the source code for a detailed description
 ** of what each interface routine does.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 #ifndef _BTREE_H_
 #define _BTREE_H_
@@ -6867,7 +6867,7 @@
 ** or VDBE.  The VDBE implements an abstract machine that runs a
 ** simple program to access and modify the underlying database.
 **
-** $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 #ifndef _SQLITE_VDBE_H_
 #define _SQLITE_VDBE_H_
@@ -7259,7 +7259,7 @@
 ** subsystem.  The page cache subsystem reads and writes a file a page
 ** at a time and provides a journal for rollback.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 
 #ifndef _PAGER_H_
@@ -7427,7 +7427,7 @@
 ** This header file defines the interface that the sqlite page cache
 ** subsystem. 
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.21 2009/05/07 12:39:26 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
 */
 
 #ifndef _PCACHE_H_
@@ -7595,7 +7595,7 @@
 ** This header file is #include-ed by sqliteInt.h and thus ends up
 ** being included by 

Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
it looks like in recent version of sqlite3 the behavior had changed  
some what. I am going to check which version of sqlite3 had followed  
the old behavior and put the code into the appropriate define block.



Ilia Alshanetsky




On 19-May-09, at 1:33 PM, Matteo Beccati wrote:


Ilia Alshanetsky ha scritto:
*len is a pointer to an integer, that is being decremented to  
reduce the

overall length of the string to remove the NUL terminator. If you
remove the operation you'll end up with 2 NULs at the end of the  
string.


As I said, I coulndn't find any reference to the fact that the NUL
terminator is included in the byte count for TEXT values in  
sqlite3.h.


I don't want to argue about this, but here's a small test case that
hopefully proves that the code you added back is just useless, as it
doesn't do what you'd expect by reading the comment.

$ cat len.c; gcc -Wall len.c; ./a.out
#include stdio.h
#include assert.h

void decrease_len(int *len)
{
   *len--;
}

int main(int argc, char **argv)
{
   int len = 10;

   decrease_len(len);
   assert(len == 9);

   return 0;
}

len.c: In function ‘decrease_len’:
len.c:6: warning: value computed is not used
a.out: len.c:14: main: Assertion `len == 9' failed.
Aborted


Cheers

--
Matteo Beccati

OpenX - http://www.openx.org



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/sqlite3/libsqlite sqlite3.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 18:42:40 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/sqlite3/libsqlite  sqlite3.c 
  Log:
  Warning fix
  http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/libsqlite/sqlite3.c?r1=1.1.2.22r2=1.1.2.23diff_format=u
Index: php-src/ext/sqlite3/libsqlite/sqlite3.c
diff -u php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.22 
php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.23
--- php-src/ext/sqlite3/libsqlite/sqlite3.c:1.1.2.22Tue May 19 18:32:25 2009
+++ php-src/ext/sqlite3/libsqlite/sqlite3.c Tue May 19 18:42:08 2009
@@ -45,7 +45,7 @@
 *
 ** Internal interface definitions for SQLite.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _SQLITEINT_H_
 #define _SQLITEINT_H_
@@ -74,7 +74,7 @@
 ** 
 ** This file defines various limits of what SQLite can process.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 /*
@@ -532,7 +532,7 @@
 ** the version number) and changes its name to sqlite3.h as
 ** part of the build process.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _SQLITE3_H_
 #define _SQLITE3_H_
@@ -6052,7 +6052,7 @@
 ** This is the header file for the generic hash-table implemenation
 ** used in SQLite.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _SQLITE_HASH_H_
 #define _SQLITE_HASH_H_
@@ -6635,7 +6635,7 @@
 ** subsystem.  See comments in the source code for a detailed description
 ** of what each interface routine does.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _BTREE_H_
 #define _BTREE_H_
@@ -6867,7 +6867,7 @@
 ** or VDBE.  The VDBE implements an abstract machine that runs a
 ** simple program to access and modify the underlying database.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _SQLITE_VDBE_H_
 #define _SQLITE_VDBE_H_
@@ -7259,7 +7259,7 @@
 ** subsystem.  The page cache subsystem reads and writes a file a page
 ** at a time and provides a journal for rollback.
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 #ifndef _PAGER_H_
@@ -7427,7 +7427,7 @@
 ** This header file defines the interface that the sqlite page cache
 ** subsystem. 
 **
-** @(#) $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 #ifndef _PCACHE_H_
@@ -7595,7 +7595,7 @@
 ** This header file is #include-ed by sqliteInt.h and thus ends up
 ** being included by every source file.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #ifndef _SQLITE_OS_H_
 #define _SQLITE_OS_H_
@@ -7655,6 +7655,7 @@
 # define SQLITE_OS_WINCE 0
 #endif
 
+#include ctype.h
 
 /*
 ** Define the maximum size of a temporary filename
@@ -7870,7 +7871,7 @@
 ** Source files should #include the sqliteInt.h file and let that file
 ** include this one indirectly.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 
@@ -10184,7 +10185,7 @@
 **
 ** This file contains definitions of global variables and contants.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 
@@ -10377,7 +10378,7 @@
 ** This module implements the sqlite3_status() interface and related
 ** functionality.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 
 /*
@@ -10504,7 +10505,7 @@
 ** sqlite3RegisterDateTimeFunctions() found at the bottom of the file.
 ** All other code has file scope.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 **
 ** SQLite processes all times and dates as Julian Day numbers.  The
 ** dates and times are stored as the number of days since noon
@@ -11609,7 +11610,7 @@
 ** This file contains OS interface code that is common to all
 ** architectures.
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.1.2.23 2009/05/19 18:42:08 iliaa Exp $
 */
 #define _SQLITE_OS_C_ 1
 #undef _SQLITE_OS_C_
@@ -11889,7 +11890,7 @@
 **
 *
 **
-** $Id: sqlite3.c,v 1.1.2.22 2009/05/19 18:32:25 

[PHP-CVS] cvs: php-src /ext/sqlite3/libsqlite sqlite3.c sqlite3.h sqlite3ext.h

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 18:44:01 2009 UTC

  Modified files:  
/php-src/ext/sqlite3/libsqlite  sqlite3.c sqlite3.h sqlite3ext.h 
  Log:
  MFB: libsqlite3 3.6.14.1 upgrade
  
  http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/libsqlite/sqlite3.c?r1=1.22r2=1.23diff_format=u
Index: php-src/ext/sqlite3/libsqlite/sqlite3.c
diff -u php-src/ext/sqlite3/libsqlite/sqlite3.c:1.22 
php-src/ext/sqlite3/libsqlite/sqlite3.c:1.23
--- php-src/ext/sqlite3/libsqlite/sqlite3.c:1.22Thu May  7 12:41:25 2009
+++ php-src/ext/sqlite3/libsqlite/sqlite3.c Tue May 19 18:44:00 2009
@@ -4,7 +4,7 @@
 
 /**
 ** This file is an amalgamation of many separate C source files from SQLite
-** version 3.6.14.  By combining all the individual C code files into this 
+** version 3.6.14.1.  By combining all the individual C code files into this 
 ** single large file, the entire code can be compiled as a one translation
 ** unit.  This allows many compilers to do optimizations that would not be
 ** possible if the files were compiled separately.  Performance improvements
@@ -21,7 +21,7 @@
 ** is also in a separate file.  This file contains only code for the core
 ** SQLite library.
 **
-** This amalgamation was generated on 2009-05-07 01:56:00 UTC.
+** This amalgamation was generated on 2009-05-18 18:33:54 UTC.
 */
 #define SQLITE_CORE 1
 #define SQLITE_AMALGAMATION 1
@@ -45,7 +45,7 @@
 *
 ** Internal interface definitions for SQLite.
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _SQLITEINT_H_
 #define _SQLITEINT_H_
@@ -74,7 +74,7 @@
 ** 
 ** This file defines various limits of what SQLite can process.
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 /*
@@ -532,7 +532,7 @@
 ** the version number) and changes its name to sqlite3.h as
 ** part of the build process.
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _SQLITE3_H_
 #define _SQLITE3_H_
@@ -601,7 +601,7 @@
 **
 ** Requirements: [H10011] [H10014]
 */
-#define SQLITE_VERSION 3.6.14
+#define SQLITE_VERSION 3.6.14.1
 #define SQLITE_VERSION_NUMBER  3006014
 
 /*
@@ -6052,7 +6052,7 @@
 ** This is the header file for the generic hash-table implemenation
 ** used in SQLite.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _SQLITE_HASH_H_
 #define _SQLITE_HASH_H_
@@ -6635,7 +6635,7 @@
 ** subsystem.  See comments in the source code for a detailed description
 ** of what each interface routine does.
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _BTREE_H_
 #define _BTREE_H_
@@ -6867,7 +6867,7 @@
 ** or VDBE.  The VDBE implements an abstract machine that runs a
 ** simple program to access and modify the underlying database.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _SQLITE_VDBE_H_
 #define _SQLITE_VDBE_H_
@@ -7259,7 +7259,7 @@
 ** subsystem.  The page cache subsystem reads and writes a file a page
 ** at a time and provides a journal for rollback.
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 #ifndef _PAGER_H_
@@ -7427,7 +7427,7 @@
 ** This header file defines the interface that the sqlite page cache
 ** subsystem. 
 **
-** @(#) $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** @(#) $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 #ifndef _PCACHE_H_
@@ -7595,7 +7595,7 @@
 ** This header file is #include-ed by sqliteInt.h and thus ends up
 ** being included by every source file.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 #ifndef _SQLITE_OS_H_
 #define _SQLITE_OS_H_
@@ -7871,7 +7871,7 @@
 ** Source files should #include the sqliteInt.h file and let that file
 ** include this one indirectly.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 
@@ -10185,7 +10185,7 @@
 **
 ** This file contains definitions of global variables and contants.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 
@@ -10378,7 +10378,7 @@
 ** This module implements the sqlite3_status() interface and related
 ** functionality.
 **
-** $Id: sqlite3.c,v 1.22 2009/05/07 12:41:25 iliaa Exp $
+** $Id: sqlite3.c,v 1.23 2009/05/19 18:44:00 iliaa Exp $
 */
 
 /*

[PHP-CVS] cvs: win-installer / GenExtensionsComponents.wxs.php

2009-05-19 Thread John Mertic
jmertic Tue May 19 19:02:36 2009 UTC

  Modified files:  
/win-installer  GenExtensionsComponents.wxs.php 
  Log:
  Bug 48302: Have correct name for the icu*.dll files after installation.
  
http://cvs.php.net/viewvc.cgi/win-installer/GenExtensionsComponents.wxs.php?r1=1.19r2=1.20diff_format=u
Index: win-installer/GenExtensionsComponents.wxs.php
diff -u win-installer/GenExtensionsComponents.wxs.php:1.19 
win-installer/GenExtensionsComponents.wxs.php:1.20
--- win-installer/GenExtensionsComponents.wxs.php:1.19  Fri Mar 20 20:36:58 2009
+++ win-installer/GenExtensionsComponents.wxs.php   Tue May 19 19:02:35 2009
@@ -162,6 +162,7 @@
while ( $i  $files-length ) {
if ( in_array($files-item($i)-getAttribute('Id'),$icuFileIds) 
) {

$files-item($i)-setAttribute('Source',str_replace('36',$icuVer,$files-item($i)-getAttribute('Source')));
+   
$files-item($i)-setAttribute('Name',str_replace('36',$icuVer,$files-item($i)-getAttribute('Name')));
}
$i++;
}



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 19:15:18 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  The \0 removal is only needed prior to 3.4.0
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.18.2.4.2.3.2.8r2=1.18.2.4.2.3.2.9diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.8 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.9
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.3.2.8  Tue May 19 
16:14:13 2009
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 19:15:18 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.18.2.4.2.3.2.8 2009/05/19 16:14:13 iliaa Exp $ 
*/
+/* $Id: sqlite_statement.c,v 1.18.2.4.2.3.2.9 2009/05/19 19:15:18 iliaa Exp $ 
*/
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -265,12 +265,13 @@
case SQLITE3_TEXT:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+#if SQLITE_VERSION_NUMBER  3004000
if (*len) {
/* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
-   *len--; /* do not remove this, even though it 
generates a warning */
+   (*len)--;
}
+#endif
return 1;
-   
default:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);



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



[PHP-CVS] cvs: php-src /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 19:16:06 2009 UTC

  Modified files:  
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  
  MFB: The \0 removal is only needed prior to 3.4.0
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.33r2=1.34diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.33 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.34
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.33  Tue May 19 16:14:46 2009
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 19:16:05 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.33 2009/05/19 16:14:46 iliaa Exp $ */
+/* $Id: sqlite_statement.c,v 1.34 2009/05/19 19:16:05 iliaa Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -265,12 +265,13 @@
case SQLITE3_TEXT:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+#if SQLITE_VERSION_NUMBER  3004000
if (*len) {
/* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
-   *len--; /* do not remove this, even though it 
generates a warning */
+   (*len)--;
}
+#endif
return 1;
-   
default:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);



-- 
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/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Ilia Alshanetsky
iliaa   Tue May 19 19:20:01 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_sqlite sqlite_statement.c 
  Log:
  
  MFB:  The \0 removal is only needed prior to 3.4.0
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.18.2.4.2.6r2=1.18.2.4.2.7diff_format=u
Index: php-src/ext/pdo_sqlite/sqlite_statement.c
diff -u php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.6 
php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.7
--- php-src/ext/pdo_sqlite/sqlite_statement.c:1.18.2.4.2.6  Tue May 19 
16:14:37 2009
+++ php-src/ext/pdo_sqlite/sqlite_statement.c   Tue May 19 19:20:01 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: sqlite_statement.c,v 1.18.2.4.2.6 2009/05/19 16:14:37 iliaa Exp $ */
+/* $Id: sqlite_statement.c,v 1.18.2.4.2.7 2009/05/19 19:20:01 iliaa Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -244,10 +244,12 @@
default:
*ptr = (char*)sqlite3_column_text(S-stmt, colno);
*len = sqlite3_column_bytes(S-stmt, colno);
+#if SQLITE_VERSION_NUMBER  3004000
if (*len) {
/* sqlite3.h says the NUL terminator is 
included in the byte count for TEXT values */
-   *len--; /* do not remove this, even though it 
generates a warning */
+   (*len)--;
}
+#endif
return 1;
}
 }



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



[PHP-CVS] cvs: php-src /ext/date php_date.c

2009-05-19 Thread Hannes Magnusson
bjori   Tue May 19 19:23:12 2009 UTC

  Modified files:  
/php-src/ext/date   php_date.c 
  Log:
  Partial fix for bug#48333 (DateInterval.format() expects a single,
  undocumented parameter)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.232r2=1.233diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.232 php-src/ext/date/php_date.c:1.233
--- php-src/ext/date/php_date.c:1.232   Tue May 19 15:38:21 2009
+++ php-src/ext/date/php_date.c Tue May 19 19:23:12 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.232 2009/05/19 15:38:21 jani Exp $ */
+/* $Id: php_date.c,v 1.233 2009/05/19 19:23:12 bjori Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -340,11 +340,13 @@
ZEND_ARG_INFO(0, time)
 ZEND_END_ARG_INFO()
 
-ZEND_BEGIN_ARG_INFO_EX(arginfo_date_interval_format, 0, 0, 1)
+ZEND_BEGIN_ARG_INFO_EX(arginfo_date_interval_format, 0, 0, 2)
ZEND_ARG_INFO(0, object)
+   ZEND_ARG_INFO(0, format)
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_INFO(arginfo_date_method_interval_format, 0)
+   ZEND_ARG_INFO(0, format)
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_INFO_EX(arginfo_date_period_construct, 0, 0, 3)



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/date php_date.c

2009-05-19 Thread Hannes Magnusson
bjori   Tue May 19 19:23:33 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/date   php_date.c 
  Log:
  MFH: Partial fix for bug#48333
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.43.2.45.2.51.2.76r2=1.43.2.45.2.51.2.77diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.43.2.45.2.51.2.76 
php-src/ext/date/php_date.c:1.43.2.45.2.51.2.77
--- php-src/ext/date/php_date.c:1.43.2.45.2.51.2.76 Tue May 19 15:38:07 2009
+++ php-src/ext/date/php_date.c Tue May 19 19:23:33 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.43.2.45.2.51.2.76 2009/05/19 15:38:07 jani Exp $ */
+/* $Id: php_date.c,v 1.43.2.45.2.51.2.77 2009/05/19 19:23:33 bjori Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -339,11 +339,13 @@
ZEND_ARG_INFO(0, time)
 ZEND_END_ARG_INFO()
 
-ZEND_BEGIN_ARG_INFO_EX(arginfo_date_interval_format, 0, 0, 1)
+ZEND_BEGIN_ARG_INFO_EX(arginfo_date_interval_format, 0, 0, 2)
ZEND_ARG_INFO(0, object)
+   ZEND_ARG_INFO(0, format)
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_INFO(arginfo_date_method_interval_format, 0)
+   ZEND_ARG_INFO(0, format)
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_INFO_EX(arginfo_date_period_construct, 0, 0, 3)
@@ -3570,7 +3572,7 @@
 }
 /* }}} */
 
-/* {{{ proto string date_interval_format(DateInterval object)
+/* {{{ proto string date_interval_format(DateInterval object, string format)
Formats the interval.
 */
 PHP_FUNCTION(date_interval_format)



-- 
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 dns.h

2009-05-19 Thread Jani Taskinen
janiTue May 19 19:38:00 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/standard   dns.h 
  Log:
  ws
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.h?r1=1.19.2.1.2.4r2=1.19.2.1.2.5diff_format=u
Index: php-src/ext/standard/dns.h
diff -u php-src/ext/standard/dns.h:1.19.2.1.2.4 
php-src/ext/standard/dns.h:1.19.2.1.2.5
--- php-src/ext/standard/dns.h:1.19.2.1.2.4 Tue May 19 11:12:33 2009
+++ php-src/ext/standard/dns.h  Tue May 19 19:38:00 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: dns.h,v 1.19.2.1.2.4 2009/05/19 11:12:33 jani Exp $ */
+/* $Id: dns.h,v 1.19.2.1.2.5 2009/05/19 19:38:00 jani Exp $ */
 
 #ifndef DNS_H
 #define DNS_H
@@ -32,18 +32,14 @@
 PHP_FUNCTION(gethostbynamel);
 
 #if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
-
 PHP_FUNCTION(dns_check_record);
 # if HAVE_DN_SKIPNAME  HAVE_DN_EXPAND
 PHP_FUNCTION(dns_get_mx);
 # endif
 
 # if HAVE_DNS_FUNCS
-
 PHP_FUNCTION(dns_get_record);
-
 PHP_MINIT_FUNCTION(dns);
-
 # endif
 #endif
 



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



[PHP-CVS] cvs: php-src /ext/standard dns.h

2009-05-19 Thread Jani Taskinen
janiTue May 19 19:39:42 2009 UTC

  Modified files:  
/php-src/ext/standard   dns.h 
  Log:
  - Fix bug #48317 (compile failure in dns.h) (thanks to Pierre for introducing 
this)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.h?r1=1.27r2=1.28diff_format=u
Index: php-src/ext/standard/dns.h
diff -u php-src/ext/standard/dns.h:1.27 php-src/ext/standard/dns.h:1.28
--- php-src/ext/standard/dns.h:1.27 Tue Mar 10 23:39:39 2009
+++ php-src/ext/standard/dns.h  Tue May 19 19:39:42 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: dns.h,v 1.27 2009/03/10 23:39:39 helly Exp $ */
+/* $Id: dns.h,v 1.28 2009/05/19 19:39:42 jani Exp $ */
 
 #ifndef DNS_H
 #define DNS_H
@@ -48,15 +48,13 @@
 #endif
 
 #if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
-
+PHP_FUNCTION(dns_check_record);
 # if defined(PHP_WIN32) || (HAVE_DN_SKIPNAME  HAVE_DN_EXPAND)
 PHP_FUNCTION(dns_get_mx);
-PHP_FUNCTION(dns_check_record);
 # endif
 
 #if defined(PHP_WIN32) || HAVE_DNS_FUNCS
 PHP_FUNCTION(dns_get_record);
-
 PHP_MINIT_FUNCTION(dns);
 # endif
 



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



[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard dns.h

2009-05-19 Thread Jani Taskinen
janiTue May 19 19:39:53 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/standard   dns.h 
  Log:
  MFH:- Fix bug #48317 (compile failure in dns.h) (thanks to Pierre for 
introducing this)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.h?r1=1.19.2.1.2.1.2.5r2=1.19.2.1.2.1.2.6diff_format=u
Index: php-src/ext/standard/dns.h
diff -u php-src/ext/standard/dns.h:1.19.2.1.2.1.2.5 
php-src/ext/standard/dns.h:1.19.2.1.2.1.2.6
--- php-src/ext/standard/dns.h:1.19.2.1.2.1.2.5 Sun Jan 11 23:37:16 2009
+++ php-src/ext/standard/dns.h  Tue May 19 19:39:53 2009
@@ -18,7 +18,7 @@
+--+
 */
 
-/* $Id: dns.h,v 1.19.2.1.2.1.2.5 2009/01/11 23:37:16 scottmac Exp $ */
+/* $Id: dns.h,v 1.19.2.1.2.1.2.6 2009/05/19 19:39:53 jani Exp $ */
 
 #ifndef DNS_H
 #define DNS_H
@@ -48,10 +48,9 @@
 #endif
 
 #if defined(PHP_WIN32) || (HAVE_RES_SEARCH  !(defined(__BEOS__) || 
defined(NETWARE)))
-
+PHP_FUNCTION(dns_check_record);
 # if defined(PHP_WIN32) || (HAVE_DN_SKIPNAME  HAVE_DN_EXPAND)
 PHP_FUNCTION(dns_get_mx);
-PHP_FUNCTION(dns_check_record);
 # endif
 
 #if defined(PHP_WIN32) || HAVE_DNS_FUNCS



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



[PHP-CVS] cvs: php-src /ext/date php_date.c

2009-05-19 Thread Derick Rethans
derick  Tue May 19 19:43:44 2009 UTC

  Modified files:  
/php-src/ext/date   php_date.c 
  Log:
  - Getting rid of using the environment to guess timezone information from.
  #- [DOC]
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.233r2=1.234diff_format=u
Index: php-src/ext/date/php_date.c
diff -u php-src/ext/date/php_date.c:1.233 php-src/ext/date/php_date.c:1.234
--- php-src/ext/date/php_date.c:1.233   Tue May 19 19:23:12 2009
+++ php-src/ext/date/php_date.c Tue May 19 19:43:44 2009
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_date.c,v 1.233 2009/05/19 19:23:12 bjori Exp $ */
+/* $Id: php_date.c,v 1.234 2009/05/19 19:43:44 derick Exp $ */
 
 #include php.h
 #include php_streams.h
@@ -832,11 +832,6 @@
if (DATEG(timezone)  (strlen(DATEG(timezone))  0)) {
return DATEG(timezone);
}
-   /* Check environment variable */
-   env = getenv(TZ);
-   if (env  *env  timelib_timezone_id_is_valid(env, tzdb)) {
-   return env;
-   }
/* Check config setting for default timezone */
if (DATEG(default_timezone)  (strlen(DATEG(default_timezone))  0)  
timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) {
return DATEG(default_timezone);



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



Re: [PHP-CVS] cvs: php-src /ext/date php_date.c

2009-05-19 Thread Rasmus Lerdorf
Wait, what?  I can see moving it to the lowest priority, but why get rid
of it completely?

-Rasmus

Derick Rethans wrote:
 derickTue May 19 19:43:44 2009 UTC
 
   Modified files:  
 /php-src/ext/date php_date.c 
   Log:
   - Getting rid of using the environment to guess timezone information from.
   #- [DOC]
   
   
 http://cvs.php.net/viewvc.cgi/php-src/ext/date/php_date.c?r1=1.233r2=1.234diff_format=u
 Index: php-src/ext/date/php_date.c
 diff -u php-src/ext/date/php_date.c:1.233 php-src/ext/date/php_date.c:1.234
 --- php-src/ext/date/php_date.c:1.233 Tue May 19 19:23:12 2009
 +++ php-src/ext/date/php_date.c   Tue May 19 19:43:44 2009
 @@ -16,7 +16,7 @@
 +--+
   */
  
 -/* $Id: php_date.c,v 1.233 2009/05/19 19:23:12 bjori Exp $ */
 +/* $Id: php_date.c,v 1.234 2009/05/19 19:43:44 derick Exp $ */
  
  #include php.h
  #include php_streams.h
 @@ -832,11 +832,6 @@
   if (DATEG(timezone)  (strlen(DATEG(timezone))  0)) {
   return DATEG(timezone);
   }
 - /* Check environment variable */
 - env = getenv(TZ);
 - if (env  *env  timelib_timezone_id_is_valid(env, tzdb)) {
 - return env;
 - }
   /* Check config setting for default timezone */
   if (DATEG(default_timezone)  (strlen(DATEG(default_timezone))  0)  
 timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) {
   return DATEG(default_timezone);
 
 
 


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



Re: [PHP-CVS] cvs: php-src /ext/sockets sockets.c

2009-05-19 Thread Jani Taskinen

I didn't quite understand why you didn't add this in PHP_5_2 and PHP_5_3.
It's just a constant. Would even consider a bug since this should have been 
added with the other MSG_* constants. :)


--Jani


Arnaud Le Blanc kirjoitti:

lbarnaudTue May 19 11:57:52 2009 UTC

  Modified files:  
/php-src/ext/sockets	sockets.c 
  Log:

  Fixed bug #48326 (constant MSG_DONTWAIT not defined)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/sockets/sockets.c?r1=1.213r2=1.214diff_format=u

Index: php-src/ext/sockets/sockets.c
diff -u php-src/ext/sockets/sockets.c:1.213 php-src/ext/sockets/sockets.c:1.214
--- php-src/ext/sockets/sockets.c:1.213 Sun May 10 01:00:15 2009
+++ php-src/ext/sockets/sockets.c   Tue May 19 11:57:52 2009
@@ -19,7 +19,7 @@
+--+
  */
 
-/* $Id: sockets.c,v 1.213 2009/05/10 01:00:15 felipe Exp $ */

+/* $Id: sockets.c,v 1.214 2009/05/19 11:57:52 lbarnaud Exp $ */
 
 #ifdef HAVE_CONFIG_H

 #include config.h
@@ -620,6 +620,9 @@
REGISTER_LONG_CONSTANT(SOCK_RDM,SOCK_RDM,   
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_OOB, MSG_OOB,
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_WAITALL, MSG_WAITALL,CONST_CS | 
CONST_PERSISTENT);
+#ifdef MSG_DONTWAIT
+   REGISTER_LONG_CONSTANT(MSG_DONTWAIT,MSG_DONTWAIT,   CONST_CS 
| CONST_PERSISTENT);
+#endif
REGISTER_LONG_CONSTANT(MSG_PEEK,MSG_PEEK,   
CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT(MSG_DONTROUTE, MSG_DONTROUTE,CONST_CS 
| CONST_PERSISTENT);
 #ifdef MSG_EOR






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



Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard file.c

2009-05-19 Thread Jani Taskinen
Yes, the code indeed is very different. I suggest you look in the mirror to find 
out who to blame. And then do a diff -u between file.c on PHP_5_2, PHP_5_3 and 
HEAD. Make your life easier and sync the files between branches before you 
commit any more fixes..


--Jani

p.s. I found 1 other bug not being fixed in HEAD by very quick diff and cvs log 
rumba. Guess who committed that one?


Ilia Alshanetsky kirjoitti:
Work in progress, the code is very different there and the patch will be 
very different.



Ilia Alshanetsky




On 18-May-09, at 5:19 PM, Jani Taskinen wrote:


What about HEAD?

--Jani


Ilia Alshanetsky kirjoitti:

iliaaMon May 18 18:45:30 2009 UTC
 Modified files:  (Branch: PHP_5_3)
   /php-src/ext/standardfile.c   Log:
   Fixed bug #48313 (fgetcsv() does not return null for empty rows)

http://cvs.php.net/viewvc.cgi/php-src/ext/standard/file.c?r1=1.409.2.6.2.28.2.32r2=1.409.2.6.2.28.2.33diff_format=u 


Index: php-src/ext/standard/file.c
diff -u php-src/ext/standard/file.c:1.409.2.6.2.28.2.32 
php-src/ext/standard/file.c:1.409.2.6.2.28.2.33
--- php-src/ext/standard/file.c:1.409.2.6.2.28.2.32Fri May  8 
09:44:17 2009

+++ php-src/ext/standard/file.cMon May 18 18:45:30 2009
@@ -21,7 +21,7 @@
   
+--+

*/
-/* $Id: file.c,v 1.409.2.6.2.28.2.32 2009/05/08 09:44:17 lbarnaud 
Exp $ */

+/* $Id: file.c,v 1.409.2.6.2.28.2.33 2009/05/18 18:45:30 iliaa Exp $ */
 /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */
@@ -2343,8 +2343,12 @@
}
 /* 3. Now pass our field back to php */
-*comp_end = '\0';
-add_next_index_stringl(return_value, temp, comp_end - temp, 1);
+if (comp_end - temp) {
+*comp_end = '\0';
+add_next_index_stringl(return_value, temp, comp_end - 
temp, 1);

+} else {
+add_next_index_null(return_value);
+}
} while (inc_len  0);
 out:



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






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



Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite sqlite_statement.c

2009-05-19 Thread Matteo Beccati
Ilia Alshanetsky ha scritto:
 iliaa Tue May 19 19:15:18 2009 UTC
 
   Modified files:  (Branch: PHP_5_3)
 /php-src/ext/pdo_sqlite   sqlite_statement.c 
   Log:
   The \0 removal is only needed prior to 3.4.0

I hate to do this (and as a php-src newbie I'm a bit afraid to), but
once again this is simply wrong. The commit breaks compatibility with
sqlite  3.4.0.

You are trying to fix something that has never been broken. The
sqlite3.h comment was wrong and the missing parens were leading you to
think that the issue existed and was being worked around in PHP.

Otherwise PDO_SQLITE would have been returning strings with trailing
'\0' since Feb 2005 to June 2007, which is quite unlikely. See:

http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/sqlite_statement.c?r1=1.12r2=1.13view=patch
http://www.sqlite.org/changes.html#version_3_4_0

I've verified the compatibility break by compiling PHP 5.3 with a cvs
checkout of sqlite 3.3.8 (-D 2007-01-01). Here's the result of one of
the many failing tests:

TEST 6/14 [ext/pdo_sqlite/tests/bug46139.phpt]
DIFF
002+ 'fo'
002- 'foo'
004+ 'fo'
004- 'foo'
006+ 'fo'
006- 'foo'
DONE

I hope this is enough proof to back up my theory and for you to revert
your latest changes.


Cheers
-- 
Matteo Beccati

OpenX - http://www.openx.org

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