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

2009-02-09 Thread changelog
changelog   Tue Feb 10 01:32:40 2009 UTC

  Modified files:  
/php-srcChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/php-src/ChangeLog?r1=1.3313r2=1.3314diff_format=u
Index: php-src/ChangeLog
diff -u php-src/ChangeLog:1.3313 php-src/ChangeLog:1.3314
--- php-src/ChangeLog:1.3313Mon Feb  9 01:32:47 2009
+++ php-src/ChangeLog   Tue Feb 10 01:32:39 2009
@@ -1,3 +1,82 @@
+2009-02-09  Felipe Pena  felipe...@gmail.com
+
+* ext/interbase/tests/ibase_affected_rows_001.phpt
+  ext/interbase/tests/ibase_errmsg_001.phpt
+  ext/interbase/tests/ibase_num_params_001.phpt:
+  - Fix tests
+
+2009-02-09  Ilia Alshanetsky  i...@prohost.org
+
+* ext/mbstring/mbstring.c
+  ext/mbstring/mbstring.c:
+  
+  MFB: Initialize optional var
+
+* (PHP_5_3)
+  ext/mbstring/mbstring.c:
+  
+  Initialize optional var
+
+2009-02-09  Greg Beaver  g...@chiaraquartet.net
+
+* (PHP_5_3)
+  NEWS:
+  remove entry for bug #46026, this is fixed in 5.2 now, and needs no 5.3
+  entry
+
+2009-02-09  Felipe Pena  felipe...@gmail.com
+
+* ext/pdo_firebird/tests/ddl.phpt:
+  - Fix test
+
+* ext/pdo_firebird/firebird_statement.c:
+  - Fix mem. leak
+
+* ext/pdo_firebird/tests/execute.phpt:
+  - Fixed test
+
+2009-02-09  Dmitry Stogov  dmi...@zend.com
+
+* (PHP_5_3)
+  NEWS
+  ext/standard/array.c
+  ext/standard/array.c:
+  Fixed bug #47329 (Crash in garbage collector)
+
+* ZendEngine2/tests/bug47320.phpt
+  ZendEngine2/tests/bug47320.phpt:
+  
+  file bug47320.phpt was initially added on branch PHP_5_3.
+
+* (PHP_5_3)
+  NEWS
+  ZendEngine2/zend_execute_API.c
+  ZendEngine2/zend_execute_API.c
+  ZendEngine2/tests/bug47320.phpt
+  main/main.c
+  main/main.c:
+  Fixed bug #47320 ($php_errormsg out of scope in functions)
+
+* ZendEngine2/zend_gc.c
+  ZendEngine2/zend_gc.c
+  ZendEngine2/tests/gc_031.phpt:
+  Better fix for #47341
+
+2009-02-09  Greg Beaver  g...@chiaraquartet.net
+
+* (PHP_5_2)
+  NEWS
+  ext/bz2/bz2_filter.c:
+  MFB fix Bug #46026 (this is a refinement of the previous fix)
+
+2009-02-09  Ilia Alshanetsky  i...@prohost.org
+
+* (PHP_5_3)
+  main/streams/xp_socket.c:
+  
+  MFB: Fixed bug #44874 (dead pfsockopen'ed sockets aren't reaped when
+  the remote end restarts)
+
 2009-02-08  Lukas Smith  sm...@pooteeweet.org
 
 * README.RELEASE_PROCESS:
@@ -29555,7 +29634,7 @@
 
 * sapi/litespeed/lsapi_main.c
   sapi/litespeed/lsapilib.c:
-  - Added missing $Id: ChangeLog,v 1.3313 2009/02/09 01:32:47 changelog 
Exp $ tags and nuked c++ comments
+  - Added missing $Id: ChangeLog,v 1.3314 2009/02/10 01:32:39 changelog 
Exp $ tags and nuked c++ comments
 
 * (PHP_5_3)
   ext/intl/locale/locale.c




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

2009-02-09 Thread changelog
changelog   Tue Feb 10 01:32:44 2009 UTC

  Modified files:  
/ZendEngine2ChangeLog 
  Log:
  ChangeLog update
  
http://cvs.php.net/viewvc.cgi/ZendEngine2/ChangeLog?r1=1.1441r2=1.1442diff_format=u
Index: ZendEngine2/ChangeLog
diff -u ZendEngine2/ChangeLog:1.1441 ZendEngine2/ChangeLog:1.1442
--- ZendEngine2/ChangeLog:1.1441Mon Feb  9 01:32:54 2009
+++ ZendEngine2/ChangeLog   Tue Feb 10 01:32:44 2009
@@ -1,3 +1,20 @@
+2009-02-09  Dmitry Stogov  dmi...@zend.com
+
+* zend_execute_API.c
+  zend_execute_API.c
+  tests/bug47320.phpt:
+  Fixed bug #47320 ($php_errormsg out of scope in functions)
+
+* tests/bug47320.phpt
+  tests/bug47320.phpt:
+  
+  file bug47320.phpt was initially added on branch PHP_5_3.
+
+* zend_gc.c
+  zend_gc.c
+  tests/gc_031.phpt:
+  Better fix for #47341
+
 2009-02-08  Derick Rethans  p...@derickrethans.nl
 
 * (PHP_5_3)
@@ -27760,7 +2,7 @@
 2003-06-10  Jani Taskinen  sni...@iki.fi
 
 * zend_multiply.h:
-  - Missing $Id: ChangeLog,v 1.1441 2009/02/09 01:32:54 changelog Exp $ tag
+  - Missing $Id: ChangeLog,v 1.1442 2009/02/10 01:32:44 changelog Exp $ tag
 
 2003-06-10  James Cox  ja...@imajes.info
 
@@ -29484,7 +29501,7 @@
   zend_types.h
   zend_variables.c
   zend_variables.h:
-  - Added some missing CVS $Id: ChangeLog,v 1.1441 2009/02/09 01:32:54 
changelog Exp $ tags, headers and footers.
+  - Added some missing CVS $Id: ChangeLog,v 1.1442 2009/02/10 01:32:44 
changelog Exp $ tags, headers and footers.
 
 2003-01-30  Ilia Alshanetsky  i...@prohost.org
 




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

2009-02-09 Thread Dmitry Stogov
dmitry  Mon Feb  9 10:47:09 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
/php-src/ext/standard   array.c 
  Log:
  Fixed bug #47329 (Crash in garbage collector)
  
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.488r2=1.2027.2.547.2.965.2.489diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.488 
php-src/NEWS:1.2027.2.547.2.965.2.489
--- php-src/NEWS:1.2027.2.547.2.965.2.488   Mon Feb  9 09:20:34 2009
+++ php-src/NEWSMon Feb  9 10:47:08 2009
@@ -1,6 +1,7 @@
 PHPNEWS
 |||
 ?? ??? 2009, PHP 5.3.0 Beta 2
+- Fixed bug #47329 (Crash in garbage collector). (Dmitry)
 - Fixed bug #47320 ($php_errormsg out of scope in functions). (Dmitry)
 - Fixed bug #47265 (generating phar.phar failes because of safe_mode). (Greg)
 - Fixed bug #47229 (preg_quote() should escape the '-' char). (Nuno)
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.308.2.21.2.37.2.50r2=1.308.2.21.2.37.2.51diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.308.2.21.2.37.2.50 
php-src/ext/standard/array.c:1.308.2.21.2.37.2.51
--- php-src/ext/standard/array.c:1.308.2.21.2.37.2.50   Wed Dec 31 11:15:44 2008
+++ php-src/ext/standard/array.cMon Feb  9 10:47:09 2009
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.308.2.21.2.37.2.50 2008/12/31 11:15:44 sebastian Exp $ */
+/* $Id: array.c,v 1.308.2.21.2.37.2.51 2009/02/09 10:47:09 dmitry Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -1965,6 +1965,7 @@
zval ***args,   /* Function arguments array */
   *stack;  /* Input stack */
HashTable *new_hash;/* New hashtable for the stack */
+   HashTable  old_hash;
int argc;   /* Number of function arguments 
*/

if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, a+, stack, 
args, argc) == FAILURE) {
@@ -1974,12 +1975,13 @@
/* Use splice to insert the elements at the beginning. Destroy old
 * hashtable and replace it with new one */
new_hash = php_splice(Z_ARRVAL_P(stack), 0, 0, args[0], argc, NULL);
-   zend_hash_destroy(Z_ARRVAL_P(stack));
+   old_hash = *Z_ARRVAL_P(stack);
if (Z_ARRVAL_P(stack) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(stack) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up and return the number of elements in the stack */
efree(args);
@@ -1996,6 +1998,7 @@
 ***repl = NULL;/* Replacement elements */
HashTable *new_hash = NULL, /* Output array's hash */
 **rem_hash = NULL; /* Removed elements' hash */
+   HashTable  old_hash;
Bucket *p;  /* Bucket used for 
traversing hash */
longi,
offset,
@@ -2053,12 +2056,13 @@
new_hash = php_splice(Z_ARRVAL_P(array), offset, length, repl, 
repl_num, rem_hash);
 
/* Replace input array's hashtable with the new one */
-   zend_hash_destroy(Z_ARRVAL_P(array));
+   old_hash = *Z_ARRVAL_P(array);
if (Z_ARRVAL_P(array) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(array) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up */
if (ZEND_NUM_ARGS() == 4) {
@@ -2532,6 +2536,7 @@
zval  *pad_value;   /* Padding value obviously */
zval ***pads;   /* Array to pass to splice */
HashTable *new_hash;/* Return value from splice */
+   HashTable  old_hash;
long pad_size;  /* Size to pad to */
long pad_size_abs;  /* Absolute value of pad_size */
int input_size; /* Size of the input array */
@@ -2581,12 +2586,13 @@
}
 
/* Copy the result hash into return value */
-   zend_hash_destroy(Z_ARRVAL_P(return_value));
+   old_hash = *Z_ARRVAL_P(return_value);
if (Z_ARRVAL_P(return_value) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(return_value) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up */
efree(pads);



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



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

2009-02-09 Thread Dmitry Stogov
dmitry  Mon Feb  9 10:47:19 2009 UTC

  Modified files:  
/php-src/ext/standard   array.c 
  Log:
  Fixed bug #47329 (Crash in garbage collector)
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.470r2=1.471diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.470 php-src/ext/standard/array.c:1.471
--- php-src/ext/standard/array.c:1.470  Wed Dec 31 11:12:36 2008
+++ php-src/ext/standard/array.cMon Feb  9 10:47:19 2009
@@ -21,7 +21,7 @@
+--+
 */
 
-/* $Id: array.c,v 1.470 2008/12/31 11:12:36 sebastian Exp $ */
+/* $Id: array.c,v 1.471 2009/02/09 10:47:19 dmitry Exp $ */
 
 #include php.h
 #include php_ini.h
@@ -2149,6 +2149,7 @@
zval ***args,   /* Function arguments array */
   *stack;  /* Input stack */
HashTable *new_hash;/* New hashtable for the stack */
+   HashTable  old_hash;
int argc;   /* Number of function arguments 
*/
 
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, a+, stack, 
args, argc) == FAILURE) {
@@ -2158,12 +2159,13 @@
/* Use splice to insert the elements at the beginning. Destroy old
 * hashtable and replace it with new one */
new_hash = php_splice(Z_ARRVAL_P(stack), 0, 0, args[0], argc, NULL);
-   zend_hash_destroy(Z_ARRVAL_P(stack));
+   old_hash = *Z_ARRVAL_P(stack);
if (Z_ARRVAL_P(stack) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(stack) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up and return the number of elements in the stack */
efree(args);
@@ -2180,6 +2182,7 @@
 ***repl = NULL;/* Replacement elements */
HashTable *new_hash = NULL, /* Output array's hash */
 **rem_hash = NULL; /* Removed elements' hash */
+   HashTable  old_hash;
Bucket *p;  /* Bucket used for 
traversing hash */
longi,
offset,
@@ -2237,12 +2240,13 @@
new_hash = php_splice(Z_ARRVAL_P(array), offset, length, repl, 
repl_num, rem_hash);
 
/* Replace input array's hashtable with the new one */
-   zend_hash_destroy(Z_ARRVAL_P(array));
+   old_hash = *Z_ARRVAL_P(array);
if (Z_ARRVAL_P(array) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(array) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up */
if (ZEND_NUM_ARGS() == 4) {
@@ -2746,6 +2750,7 @@
zval  *pad_value;   /* Padding value obviously */
zval ***pads;   /* Array to pass to splice */
HashTable *new_hash;/* Return value from splice */
+   HashTable  old_hash;
long pad_size;  /* Size to pad to */
long pad_size_abs;  /* Absolute value of pad_size */
int input_size; /* Size of the input array */
@@ -2795,12 +2800,13 @@
}
 
/* Copy the result hash into return value */
-   zend_hash_destroy(Z_ARRVAL_P(return_value));
+   old_hash = *Z_ARRVAL_P(return_value);
if (Z_ARRVAL_P(return_value) == EG(symbol_table)) {
zend_reset_all_cv(EG(symbol_table) TSRMLS_CC);
}
*Z_ARRVAL_P(return_value) = *new_hash;
FREE_HASHTABLE(new_hash);
+   zend_hash_destroy(old_hash);
 
/* Clean up */
efree(pads);



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



[PHP-CVS] cvs: php-src /ext/pdo_firebird/tests execute.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 11:57:30 2009 UTC

  Modified files:  
/php-src/ext/pdo_firebird/tests execute.phpt 
  Log:
  - Fixed test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/execute.phpt?r1=1.4r2=1.5diff_format=u
Index: php-src/ext/pdo_firebird/tests/execute.phpt
diff -u php-src/ext/pdo_firebird/tests/execute.phpt:1.4 
php-src/ext/pdo_firebird/tests/execute.phpt:1.5
--- php-src/ext/pdo_firebird/tests/execute.phpt:1.4 Wed Jun 23 13:26:09 2004
+++ php-src/ext/pdo_firebird/tests/execute.phpt Mon Feb  9 11:57:29 2009
@@ -5,15 +5,15 @@
 --INI--
 ibase.timestampformat=%Y-%m-%d %H:%M:%S
 --FILE--
-?php /* $Id: execute.phpt,v 1.4 2004/06/23 13:26:09 abies Exp $ */
+?php /* $Id: execute.phpt,v 1.5 2009/02/09 11:57:29 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
 
-   var_dump($db-getAttribute(PDO_ATTR_CONNECTION_STATUS));
+   var_dump($db-getAttribute(PDO::ATTR_CONNECTION_STATUS));
 
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);
 
$db-exec(CREATE TABLE ddl (id SMALLINT NOT NULL PRIMARY KEY, text 
VARCHAR(32),
datetime TIMESTAMP DEFAULT '2000-02-12' NOT NULL));
@@ -21,11 +21,13 @@

$s = $db-prepare(SELECT * FROM ddl WHERE id=? FOR UPDATE);
 
-   $s-bindParam(1,$id = 0);
-   $s-bindColumn(TEXT,$var = null);
+   $id = 0;
+   $s-bindParam(1,$id);
+   $var = null;
+   $s-bindColumn(TEXT,$var);
$id = 1;
$s-execute();
-   $s-setAttribute(PDO_ATTR_CURSOR_NAME, c);
+   $s-setAttribute(PDO::ATTR_CURSOR_NAME, c);

var_dump($id);
 



-- 
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_firebird/tests execute.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 11:57:44 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_firebird/tests execute.phpt 
  Log:
  - MFH: Fixed test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/execute.phpt?r1=1.4r2=1.4.6.1diff_format=u
Index: php-src/ext/pdo_firebird/tests/execute.phpt
diff -u php-src/ext/pdo_firebird/tests/execute.phpt:1.4 
php-src/ext/pdo_firebird/tests/execute.phpt:1.4.6.1
--- php-src/ext/pdo_firebird/tests/execute.phpt:1.4 Wed Jun 23 13:26:09 2004
+++ php-src/ext/pdo_firebird/tests/execute.phpt Mon Feb  9 11:57:44 2009
@@ -5,15 +5,15 @@
 --INI--
 ibase.timestampformat=%Y-%m-%d %H:%M:%S
 --FILE--
-?php /* $Id: execute.phpt,v 1.4 2004/06/23 13:26:09 abies Exp $ */
+?php /* $Id: execute.phpt,v 1.4.6.1 2009/02/09 11:57:44 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
 
-   var_dump($db-getAttribute(PDO_ATTR_CONNECTION_STATUS));
+   var_dump($db-getAttribute(PDO::ATTR_CONNECTION_STATUS));
 
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);
 
$db-exec(CREATE TABLE ddl (id SMALLINT NOT NULL PRIMARY KEY, text 
VARCHAR(32),
datetime TIMESTAMP DEFAULT '2000-02-12' NOT NULL));
@@ -21,11 +21,13 @@

$s = $db-prepare(SELECT * FROM ddl WHERE id=? FOR UPDATE);
 
-   $s-bindParam(1,$id = 0);
-   $s-bindColumn(TEXT,$var = null);
+   $id = 0;
+   $s-bindParam(1,$id);
+   $var = null;
+   $s-bindColumn(TEXT,$var);
$id = 1;
$s-execute();
-   $s-setAttribute(PDO_ATTR_CURSOR_NAME, c);
+   $s-setAttribute(PDO::ATTR_CURSOR_NAME, c);

var_dump($id);
 



-- 
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_firebird/tests execute.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 11:58:03 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_firebird/tests execute.phpt 
  Log:
  - MFH: Fixed test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/execute.phpt?r1=1.4r2=1.4.4.1diff_format=u
Index: php-src/ext/pdo_firebird/tests/execute.phpt
diff -u php-src/ext/pdo_firebird/tests/execute.phpt:1.4 
php-src/ext/pdo_firebird/tests/execute.phpt:1.4.4.1
--- php-src/ext/pdo_firebird/tests/execute.phpt:1.4 Wed Jun 23 13:26:09 2004
+++ php-src/ext/pdo_firebird/tests/execute.phpt Mon Feb  9 11:58:02 2009
@@ -5,15 +5,15 @@
 --INI--
 ibase.timestampformat=%Y-%m-%d %H:%M:%S
 --FILE--
-?php /* $Id: execute.phpt,v 1.4 2004/06/23 13:26:09 abies Exp $ */
+?php /* $Id: execute.phpt,v 1.4.4.1 2009/02/09 11:58:02 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
 
-   var_dump($db-getAttribute(PDO_ATTR_CONNECTION_STATUS));
+   var_dump($db-getAttribute(PDO::ATTR_CONNECTION_STATUS));
 
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);
 
$db-exec(CREATE TABLE ddl (id SMALLINT NOT NULL PRIMARY KEY, text 
VARCHAR(32),
datetime TIMESTAMP DEFAULT '2000-02-12' NOT NULL));
@@ -21,11 +21,13 @@

$s = $db-prepare(SELECT * FROM ddl WHERE id=? FOR UPDATE);
 
-   $s-bindParam(1,$id = 0);
-   $s-bindColumn(TEXT,$var = null);
+   $id = 0;
+   $s-bindParam(1,$id);
+   $var = null;
+   $s-bindColumn(TEXT,$var);
$id = 1;
$s-execute();
-   $s-setAttribute(PDO_ATTR_CURSOR_NAME, c);
+   $s-setAttribute(PDO::ATTR_CURSOR_NAME, c);

var_dump($id);
 



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



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

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:07:11 2009 UTC

  Modified files:  
/php-src/ext/pdo_firebird   firebird_statement.c 
  Log:
  - Fix mem. leak
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/firebird_statement.c?r1=1.25r2=1.26diff_format=u
Index: php-src/ext/pdo_firebird/firebird_statement.c
diff -u php-src/ext/pdo_firebird/firebird_statement.c:1.25 
php-src/ext/pdo_firebird/firebird_statement.c:1.26
--- php-src/ext/pdo_firebird/firebird_statement.c:1.25  Wed Dec 31 11:12:34 2008
+++ php-src/ext/pdo_firebird/firebird_statement.c   Mon Feb  9 12:07:10 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: firebird_statement.c,v 1.25 2008/12/31 11:12:34 sebastian Exp $ */
+/* $Id: firebird_statement.c,v 1.26 2009/02/09 12:07:10 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -466,6 +466,9 @@
case PDO_PARAM_EVT_ALLOC:
if (param-is_param) {
/* allocate the parameter */
+   if (var-sqlind) {
+   efree(var-sqlind);
+   }
var-sqlind = (void*)emalloc(var-sqllen + 
2*sizeof(short));
var-sqldata = 
((char*)var-sqlind)[sizeof(short)];
}



-- 
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_firebird firebird_statement.c

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:07:23 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_firebird   firebird_statement.c 
  Log:
  - MFH: Fix mem. leak
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/firebird_statement.c?r1=1.18.2.1.2.5.2.10r2=1.18.2.1.2.5.2.11diff_format=u
Index: php-src/ext/pdo_firebird/firebird_statement.c
diff -u php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.5.2.10 
php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.5.2.11
--- php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.5.2.10 Wed Dec 
31 11:15:41 2008
+++ php-src/ext/pdo_firebird/firebird_statement.c   Mon Feb  9 12:07:23 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: firebird_statement.c,v 1.18.2.1.2.5.2.10 2008/12/31 11:15:41 sebastian 
Exp $ */
+/* $Id: firebird_statement.c,v 1.18.2.1.2.5.2.11 2009/02/09 12:07:23 felipe 
Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -470,6 +470,9 @@
case PDO_PARAM_EVT_ALLOC:
if (param-is_param) {
/* allocate the parameter */
+   if (var-sqlind) {
+   efree(var-sqlind);
+   }
var-sqlind = (void*)emalloc(var-sqllen + 
2*sizeof(short));
var-sqldata = 
((char*)var-sqlind)[sizeof(short)];
}



-- 
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_firebird firebird_statement.c

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:07:35 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_firebird   firebird_statement.c 
  Log:
  - MFH: Fix mem. leak
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/firebird_statement.c?r1=1.18.2.1.2.7r2=1.18.2.1.2.8diff_format=u
Index: php-src/ext/pdo_firebird/firebird_statement.c
diff -u php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.7 
php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.8
--- php-src/ext/pdo_firebird/firebird_statement.c:1.18.2.1.2.7  Wed Dec 31 
11:17:41 2008
+++ php-src/ext/pdo_firebird/firebird_statement.c   Mon Feb  9 12:07:35 2009
@@ -16,7 +16,7 @@
   +--+
 */
 
-/* $Id: firebird_statement.c,v 1.18.2.1.2.7 2008/12/31 11:17:41 sebastian Exp 
$ */
+/* $Id: firebird_statement.c,v 1.18.2.1.2.8 2009/02/09 12:07:35 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -527,6 +527,9 @@
case PDO_PARAM_EVT_ALLOC:
if (param-is_param) {
/* allocate the parameter */
+   if (var-sqlind) {
+   efree(var-sqlind);
+   }
var-sqlind = (void*)emalloc(var-sqllen + 
2*sizeof(short));
var-sqldata = 
((char*)var-sqlind)[sizeof(short)];
}



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



[PHP-CVS] cvs: php-src /ext/pdo_firebird/tests ddl.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:55:46 2009 UTC

  Modified files:  
/php-src/ext/pdo_firebird/tests ddl.phpt 
  Log:
  - Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/ddl.phpt?r1=1.1r2=1.2diff_format=u
Index: php-src/ext/pdo_firebird/tests/ddl.phpt
diff -u php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 
php-src/ext/pdo_firebird/tests/ddl.phpt:1.2
--- php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 Sat Jun 12 03:09:48 2004
+++ php-src/ext/pdo_firebird/tests/ddl.phpt Mon Feb  9 12:55:46 2009
@@ -3,19 +3,19 @@
 --SKIPIF--
 ?php include(skipif.inc); ?
 --FILE--
-?php /* $Id: ddl.phpt,v 1.1 2004/06/12 03:09:48 abies Exp $ */
+?php /* $Id: ddl.phpt,v 1.2 2009/02/09 12:55:46 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);

$db-exec(CREATE TABLE ddl (id INT NOT NULL PRIMARY KEY, text BLOB 
SUB_TYPE 1));
$db-exec(CREATE GENERATOR gen_ddl_id);
$db-exec(CREATE TRIGGER ddl_bi FOR ddl BEFORE INSERT AS
BEGIN IF (NEW.id IS NULL) THEN NEW.id=GEN_ID(gen_ddl_id,1); 
END);

-   $db-setAttribute(PDO_ATTR_AUTOCOMMIT,0);
+   $db-setAttribute(PDO::ATTR_AUTOCOMMIT,0);

$db-beginTransaction();
var_dump($db-exec(INSERT INTO ddl (text) VALUES ('bla')));



-- 
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_firebird/tests ddl.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:56:00 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_firebird/tests ddl.phpt 
  Log:
  - MFH: Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/ddl.phpt?r1=1.1r2=1.1.6.1diff_format=u
Index: php-src/ext/pdo_firebird/tests/ddl.phpt
diff -u php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 
php-src/ext/pdo_firebird/tests/ddl.phpt:1.1.6.1
--- php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 Sat Jun 12 03:09:48 2004
+++ php-src/ext/pdo_firebird/tests/ddl.phpt Mon Feb  9 12:56:00 2009
@@ -3,19 +3,19 @@
 --SKIPIF--
 ?php include(skipif.inc); ?
 --FILE--
-?php /* $Id: ddl.phpt,v 1.1 2004/06/12 03:09:48 abies Exp $ */
+?php /* $Id: ddl.phpt,v 1.1.6.1 2009/02/09 12:56:00 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);

$db-exec(CREATE TABLE ddl (id INT NOT NULL PRIMARY KEY, text BLOB 
SUB_TYPE 1));
$db-exec(CREATE GENERATOR gen_ddl_id);
$db-exec(CREATE TRIGGER ddl_bi FOR ddl BEFORE INSERT AS
BEGIN IF (NEW.id IS NULL) THEN NEW.id=GEN_ID(gen_ddl_id,1); 
END);

-   $db-setAttribute(PDO_ATTR_AUTOCOMMIT,0);
+   $db-setAttribute(PDO::ATTR_AUTOCOMMIT,0);

$db-beginTransaction();
var_dump($db-exec(INSERT INTO ddl (text) VALUES ('bla')));



-- 
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_firebird/tests ddl.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 12:56:09 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/pdo_firebird/tests ddl.phpt 
  Log:
  - MFH: Fix test
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_firebird/tests/ddl.phpt?r1=1.1r2=1.1.4.1diff_format=u
Index: php-src/ext/pdo_firebird/tests/ddl.phpt
diff -u php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 
php-src/ext/pdo_firebird/tests/ddl.phpt:1.1.4.1
--- php-src/ext/pdo_firebird/tests/ddl.phpt:1.1 Sat Jun 12 03:09:48 2004
+++ php-src/ext/pdo_firebird/tests/ddl.phpt Mon Feb  9 12:56:09 2009
@@ -3,19 +3,19 @@
 --SKIPIF--
 ?php include(skipif.inc); ?
 --FILE--
-?php /* $Id: ddl.phpt,v 1.1 2004/06/12 03:09:48 abies Exp $ */
+?php /* $Id: ddl.phpt,v 1.1.4.1 2009/02/09 12:56:09 felipe Exp $ */
 
require(testdb.inc);
 
$db = new PDO(firebird:dbname=$test_base,$user,$password) or die;
-   $db-setAttribute(PDO_ATTR_ERRMODE, PDO_ERRMODE_WARNING);
+   $db-setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);

$db-exec(CREATE TABLE ddl (id INT NOT NULL PRIMARY KEY, text BLOB 
SUB_TYPE 1));
$db-exec(CREATE GENERATOR gen_ddl_id);
$db-exec(CREATE TRIGGER ddl_bi FOR ddl BEFORE INSERT AS
BEGIN IF (NEW.id IS NULL) THEN NEW.id=GEN_ID(gen_ddl_id,1); 
END);

-   $db-setAttribute(PDO_ATTR_AUTOCOMMIT,0);
+   $db-setAttribute(PDO::ATTR_AUTOCOMMIT,0);

$db-beginTransaction();
var_dump($db-exec(INSERT INTO ddl (text) VALUES ('bla')));



-- 
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-02-09 Thread Greg Beaver
cellog  Mon Feb  9 15:03:33 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-srcNEWS 
  Log:
  remove entry for bug #46026, this is fixed in 5.2 now, and needs no 5.3 entry
  
http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.489r2=1.2027.2.547.2.965.2.490diff_format=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.547.2.965.2.489 
php-src/NEWS:1.2027.2.547.2.965.2.490
--- php-src/NEWS:1.2027.2.547.2.965.2.489   Mon Feb  9 10:47:08 2009
+++ php-src/NEWSMon Feb  9 15:03:32 2009
@@ -8,8 +8,6 @@
 - Fixed bug #47085 (rename() returns true even if the file in PHAR does not 
exist). (Greg)
 - Fixed bug #47031 (Fix constants in DualIterator example). (Etienne)
 - Fixed bug #46347 (parse_ini_file() doesn't support * in keys). (Nuno)
-- Fixed bug #46026 (bz2.decompress/zlib.inflate filter tries to decompress 
after
-  end of stream). (Greg)
 - Fixed bug #46048 (SimpleXML top-level @attributes not part of iterator). 
(David C.)
 
 29 Jan 2009, PHP 5.3.0 Beta 1



-- 
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/mbstring mbstring.c

2009-02-09 Thread Ilia Alshanetsky
iliaa   Mon Feb  9 15:34:01 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/mbstring   mbstring.c 
  Log:
  
  Initialize optional var
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/mbstring.c?r1=1.224.2.22.2.25.2.45r2=1.224.2.22.2.25.2.46diff_format=u
Index: php-src/ext/mbstring/mbstring.c
diff -u php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.45 
php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.46
--- php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.45Thu Jan 29 
22:59:57 2009
+++ php-src/ext/mbstring/mbstring.c Mon Feb  9 15:34:01 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: mbstring.c,v 1.224.2.22.2.25.2.45 2009/01/29 22:59:57 scottmac Exp $ */
+/* $Id: mbstring.c,v 1.224.2.22.2.25.2.46 2009/02/09 15:34:01 iliaa Exp $ */
 
 /*
  * PHP 4 Multibyte String module mbstring
@@ -2034,7 +2034,7 @@
Parses GET/POST/COOKIE data and sets global variables */
 PHP_FUNCTION(mb_parse_str)
 {
-   zval *track_vars_array;
+   zval *track_vars_array = NULL;
char *encstr = NULL;
int encstr_len;
php_mb_encoding_handler_info_t info;



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



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

2009-02-09 Thread Ilia Alshanetsky
iliaa   Mon Feb  9 15:34:23 2009 UTC

  Modified files:  
/php-src/ext/mbstring   mbstring.c 
  Log:
  
  MFB: Initialize optional var
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/mbstring.c?r1=1.312r2=1.313diff_format=u
Index: php-src/ext/mbstring/mbstring.c
diff -u php-src/ext/mbstring/mbstring.c:1.312 
php-src/ext/mbstring/mbstring.c:1.313
--- php-src/ext/mbstring/mbstring.c:1.312   Thu Jan 29 23:01:40 2009
+++ php-src/ext/mbstring/mbstring.c Mon Feb  9 15:34:23 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: mbstring.c,v 1.312 2009/01/29 23:01:40 scottmac Exp $ */
+/* $Id: mbstring.c,v 1.313 2009/02/09 15:34:23 iliaa Exp $ */
 
 /*
  * PHP 4 Multibyte String module mbstring
@@ -1873,7 +1873,7 @@
Parses GET/POST/COOKIE data and sets global variables */
 PHP_FUNCTION(mb_parse_str)
 {
-   zval *track_vars_array;
+   zval *track_vars_array = NULL;
char *encstr = NULL;
int encstr_len;
php_mb_encoding_handler_info_t info;



-- 
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/mbstring mbstring.c

2009-02-09 Thread Ilia Alshanetsky
iliaa   Mon Feb  9 15:34:32 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/mbstring   mbstring.c 
  Log:
  
  MFB: Initialize optional var
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/mbstring.c?r1=1.224.2.22.2.43r2=1.224.2.22.2.44diff_format=u
Index: php-src/ext/mbstring/mbstring.c
diff -u php-src/ext/mbstring/mbstring.c:1.224.2.22.2.43 
php-src/ext/mbstring/mbstring.c:1.224.2.22.2.44
--- php-src/ext/mbstring/mbstring.c:1.224.2.22.2.43 Thu Jan 29 22:58:52 2009
+++ php-src/ext/mbstring/mbstring.c Mon Feb  9 15:34:32 2009
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: mbstring.c,v 1.224.2.22.2.43 2009/01/29 22:58:52 scottmac Exp $ */
+/* $Id: mbstring.c,v 1.224.2.22.2.44 2009/02/09 15:34:32 iliaa Exp $ */
 
 /*
  * PHP 4 Multibyte String module mbstring
@@ -1452,7 +1452,7 @@
Parses GET/POST/COOKIE data and sets global variables */
 PHP_FUNCTION(mb_parse_str)
 {
-   zval *track_vars_array;
+   zval *track_vars_array = NULL;
char *encstr = NULL;
int encstr_len;
php_mb_encoding_handler_info_t info;



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



[PHP-CVS] cvs: php-src /ext/interbase/tests ibase_affected_rows_001.phpt ibase_errmsg_001.phpt ibase_num_params_001.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 16:44:10 2009 UTC

  Modified files:  
/php-src/ext/interbase/testsibase_affected_rows_001.phpt 
ibase_errmsg_001.phpt 
ibase_num_params_001.phpt 
  Log:
  - Fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_affected_rows_001.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/interbase/tests/ibase_affected_rows_001.phpt
diff -u php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.2 
php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.3
--- php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.2Mon Nov 
10 22:33:00 2008
+++ php-src/ext/interbase/tests/ibase_affected_rows_001.phptMon Feb  9 
16:44:10 2009
@@ -28,5 +28,5 @@
 int(3)
 int(0)
 
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
 int(0)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_errmsg_001.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/interbase/tests/ibase_errmsg_001.phpt
diff -u php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.2 
php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.3
--- php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.2   Mon Nov 10 
22:33:00 2008
+++ php-src/ext/interbase/tests/ibase_errmsg_001.phpt   Mon Feb  9 16:44:10 2009
@@ -17,6 +17,6 @@
 
 ?
 --EXPECTF--
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
-string(%d) Dynamic SQL Error SQL error code = -104 Unexpected end of command 
%s
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
+string(%d) Dynamic SQL Error SQL error code = -104 %s
 bool(false)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_num_params_001.phpt?r1=1.3r2=1.4diff_format=u
Index: php-src/ext/interbase/tests/ibase_num_params_001.phpt
diff -u php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.3 
php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.4
--- php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.3   Thu Nov 27 
02:16:56 2008
+++ php-src/ext/interbase/tests/ibase_num_params_001.phpt   Mon Feb  9 
16:44:10 2009
@@ -26,7 +26,7 @@
 Warning: ibase_num_params() expects exactly 1 parameter, 0 given in %s on line 
%d
 NULL
 
-Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 Column 
unknown X At line 1, column 52  in %s on line %d
+Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 %s in %s on 
line %d
 
 Warning: ibase_num_params() expects parameter 1 to be resource, boolean given 
in %s on line %d
 NULL



-- 
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/interbase/tests ibase_affected_rows_001.phpt ibase_errmsg_001.phpt ibase_num_params_001.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 16:44:23 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/interbase/testsibase_affected_rows_001.phpt 
ibase_errmsg_001.phpt 
ibase_num_params_001.phpt 
  Log:
  - MFH: Fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_affected_rows_001.phpt?r1=1.1.2.3r2=1.1.2.4diff_format=u
Index: php-src/ext/interbase/tests/ibase_affected_rows_001.phpt
diff -u php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.2.3 
php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.2.4
--- php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.2.3Mon Nov 
10 22:33:53 2008
+++ php-src/ext/interbase/tests/ibase_affected_rows_001.phptMon Feb  9 
16:44:23 2009
@@ -28,5 +28,5 @@
 int(3)
 int(0)
 
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
 int(0)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_errmsg_001.phpt?r1=1.1.2.3r2=1.1.2.4diff_format=u
Index: php-src/ext/interbase/tests/ibase_errmsg_001.phpt
diff -u php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.2.3 
php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.2.4
--- php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.2.3   Mon Nov 10 
22:33:53 2008
+++ php-src/ext/interbase/tests/ibase_errmsg_001.phpt   Mon Feb  9 16:44:23 2009
@@ -17,6 +17,6 @@
 
 ?
 --EXPECTF--
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
-string(%d) Dynamic SQL Error SQL error code = -104 Unexpected end of command 
%s
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
+string(%d) Dynamic SQL Error SQL error code = -104 %s
 bool(false)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_num_params_001.phpt?r1=1.1.2.4r2=1.1.2.5diff_format=u
Index: php-src/ext/interbase/tests/ibase_num_params_001.phpt
diff -u php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.2.4 
php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.2.5
--- php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.2.4   Thu Nov 
27 02:17:22 2008
+++ php-src/ext/interbase/tests/ibase_num_params_001.phpt   Mon Feb  9 
16:44:23 2009
@@ -26,7 +26,7 @@
 Warning: ibase_num_params() expects exactly 1 parameter, 0 given in %s on line 
%d
 NULL
 
-Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 Column 
unknown X At line 1, column 52  in %s on line %d
+Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 %s in %s on 
line %d
 
 Warning: ibase_num_params() expects parameter 1 to be resource, boolean given 
in %s on line %d
 NULL



-- 
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/interbase/tests ibase_affected_rows_001.phpt ibase_errmsg_001.phpt ibase_num_params_001.phpt

2009-02-09 Thread Felipe Pena
felipe  Mon Feb  9 16:59:47 2009 UTC

  Modified files:  (Branch: PHP_5_2)
/php-src/ext/interbase/testsibase_affected_rows_001.phpt 
ibase_errmsg_001.phpt 
ibase_num_params_001.phpt 
  Log:
  - MFH: Fix tests
  
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_affected_rows_001.phpt?r1=1.1.4.3r2=1.1.4.4diff_format=u
Index: php-src/ext/interbase/tests/ibase_affected_rows_001.phpt
diff -u php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.4.3 
php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.4.4
--- php-src/ext/interbase/tests/ibase_affected_rows_001.phpt:1.1.4.3Mon Nov 
10 22:35:02 2008
+++ php-src/ext/interbase/tests/ibase_affected_rows_001.phptMon Feb  9 
16:59:47 2009
@@ -28,5 +28,5 @@
 int(3)
 int(0)
 
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
 int(0)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_errmsg_001.phpt?r1=1.1.4.4r2=1.1.4.5diff_format=u
Index: php-src/ext/interbase/tests/ibase_errmsg_001.phpt
diff -u php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.4.4 
php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.4.5
--- php-src/ext/interbase/tests/ibase_errmsg_001.phpt:1.1.4.4   Tue Nov 11 
18:41:59 2008
+++ php-src/ext/interbase/tests/ibase_errmsg_001.phpt   Mon Feb  9 16:59:47 2009
@@ -17,6 +17,6 @@
 
 ?
 --EXPECTF--
-Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 Unexpected end 
of command %s on line %d
-string(%d) Dynamic SQL Error SQL error code = -104 Unexpected end of 
command%s
+Warning: ibase_query(): Dynamic SQL Error SQL error code = -104 %s on line %d
+string(%d) Dynamic SQL Error SQL error code = -104 %s
 bool(false)
http://cvs.php.net/viewvc.cgi/php-src/ext/interbase/tests/ibase_num_params_001.phpt?r1=1.1.4.3r2=1.1.4.4diff_format=u
Index: php-src/ext/interbase/tests/ibase_num_params_001.phpt
diff -u php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.4.3 
php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.4.4
--- php-src/ext/interbase/tests/ibase_num_params_001.phpt:1.1.4.3   Mon Nov 
10 22:35:02 2008
+++ php-src/ext/interbase/tests/ibase_num_params_001.phpt   Mon Feb  9 
16:59:47 2009
@@ -26,7 +26,7 @@
 Warning: Wrong parameter count for ibase_num_params() in %s on line %d
 NULL
 
-Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 Column 
unknown X At line 1, column 52%s in %s on line %d
+Warning: ibase_prepare(): Dynamic SQL Error SQL error code = -206 %s in %s on 
line %d
 
 Warning: ibase_num_params(): supplied argument is not a valid 
Firebird/InterBase query resource in %s on line %d
 bool(false)



-- 
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 sqlite3.c /ext/sqlite3/tests sqlite3_15_open_error.phpt sqlite3_21_security.phpt

2009-02-09 Thread Scott MacVicar
scottmacTue Feb 10 00:24:33 2009 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/sqlite3sqlite3.c 
/php-src/ext/sqlite3/tests  sqlite3_15_open_error.phpt 
sqlite3_21_security.phpt 
  Log:
  The constructor should also throw exceptions, make this semi useful now.
  
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/sqlite3.c?r1=1.1.2.31r2=1.1.2.32diff_format=u
Index: php-src/ext/sqlite3/sqlite3.c
diff -u php-src/ext/sqlite3/sqlite3.c:1.1.2.31 
php-src/ext/sqlite3/sqlite3.c:1.1.2.32
--- php-src/ext/sqlite3/sqlite3.c:1.1.2.31  Wed Jan 28 23:58:09 2009
+++ php-src/ext/sqlite3/sqlite3.c   Tue Feb 10 00:24:33 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: sqlite3.c,v 1.1.2.31 2009/01/28 23:58:09 scottmac Exp $ */
+/* $Id: sqlite3.c,v 1.1.2.32 2009/02/10 00:24:33 scottmac Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -72,29 +72,38 @@
char *filename, *encryption_key, *fullpath;
int filename_len, encryption_key_len = 0;
long flags = SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE;
+   zend_error_handling error_handling;
+
db_obj = (php_sqlite3_db_object *)zend_object_store_get_object(object 
TSRMLS_CC);
+   zend_replace_error_handling(EH_THROW, NULL, error_handling TSRMLS_CC);
 
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, s|ls, 
filename, filename_len, flags, encryption_key, encryption_key_len)) {
+   zend_restore_error_handling(error_handling TSRMLS_CC);
return;
}
 
+   zend_restore_error_handling(error_handling TSRMLS_CC);
+
if (db_obj-initialised) {
-   php_error_docref(NULL TSRMLS_CC, E_NOTICE, Already initialised 
DB Object);
+   zend_throw_exception(zend_exception_get_default(TSRMLS_C), 
Already initialised DB Object, 0 TSRMLS_CC);
}
 
if (strncmp(filename, :memory:, 8) != 0) {
if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
-   RETURN_FALSE;
+   
zend_throw_exception(zend_exception_get_default(TSRMLS_C), Unable to expand 
filepath, 0 TSRMLS_CC);
+   return;
}
 
if (PG(safe_mode)  (!php_checkuid(fullpath, NULL, 
CHECKUID_CHECK_FILE_AND_DIR))) {
+   
zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, 
safe_mode prohibits opening %s, fullpath);
efree(fullpath);
-   RETURN_FALSE;
+   return;
}
 
if (php_check_open_basedir(fullpath TSRMLS_CC)) {
+   
zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, 
open_basedir prohibits opening %s, fullpath);
efree(fullpath);
-   RETURN_FALSE;
+   return;
}
} else {
fullpath = estrdup(filename);
@@ -105,7 +114,7 @@
 #else
if (sqlite3_open(fullpath, (db_obj-db)) != SQLITE_OK) {
 #endif
-   php_error_docref(NULL TSRMLS_CC, E_NOTICE, Unable to open 
database: %s, sqlite3_errmsg(db_obj-db));
+   zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 
TSRMLS_CC, Unable to open database: %s, sqlite3_errmsg(db_obj-db));
if (fullpath) {
efree(fullpath);
}
@@ -117,6 +126,7 @@
 #if SQLITE_HAS_CODEC
if (encryption_key_len  0) {
if (sqlite3_key(db_obj-db, encryption_key, encryption_key_len) 
!= SQLITE_OK) {
+   
zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, 
Unable to open database: %s, sqlite3_errmsg(db_obj-db));
return;
}
}
@@ -129,7 +139,6 @@
if (fullpath) {
efree(fullpath);
}
-   RETURN_TRUE;
 }
 /* }}} */
 
http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt
diff -u php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.1.2.2 
php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.1.2.3
--- php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.1.2.2Sun Jul 
27 00:05:36 2008
+++ php-src/ext/sqlite3/tests/sqlite3_15_open_error.phptTue Feb 10 
00:24:33 2009
@@ -7,14 +7,17 @@
 $unreadable = dirname(__FILE__) . '/unreadable.db';
 touch($unreadable);
 chmod($unreadable,  0200);
-$db = new SQLite3($unreadable);
-
-var_dump($db);
+try {
+   $db = new SQLite3($unreadable);
+} catch (Exception $e) {
+   echo $e . \n;
+}
 echo Done\n;
 unlink($unreadable);
 ?
 --EXPECTF--
-Notice: SQLite3::__construct(): Unable to open database: unable to open 
database file in 

[PHP-CVS] cvs: php-src /ext/sqlite3 sqlite3.c /ext/sqlite3/tests sqlite3_15_open_error.phpt sqlite3_21_security.phpt

2009-02-09 Thread Scott MacVicar
scottmacTue Feb 10 00:44:09 2009 UTC

  Modified files:  
/php-src/ext/sqlite3sqlite3.c 
/php-src/ext/sqlite3/tests  sqlite3_15_open_error.phpt 
sqlite3_21_security.phpt 
  Log:
  MFB: The constructor should also throw exceptions, make this semi useful now.
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/sqlite3.c?r1=1.34r2=1.35diff_format=u
Index: php-src/ext/sqlite3/sqlite3.c
diff -u php-src/ext/sqlite3/sqlite3.c:1.34 php-src/ext/sqlite3/sqlite3.c:1.35
--- php-src/ext/sqlite3/sqlite3.c:1.34  Wed Feb  4 09:58:39 2009
+++ php-src/ext/sqlite3/sqlite3.c   Tue Feb 10 00:44:09 2009
@@ -16,7 +16,7 @@
+--+
 */
 
-/* $Id: sqlite3.c,v 1.34 2009/02/04 09:58:39 pajoye Exp $ */
+/* $Id: sqlite3.c,v 1.35 2009/02/10 00:44:09 scottmac Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include config.h
@@ -74,36 +74,46 @@
zend_uchar filename_type;
int filename_len, encryption_key_len = 0;
long flags = SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE;
+   zend_error_handling error_handling;
+
db_obj = (php_sqlite3_db_object *)zend_object_store_get_object(object 
TSRMLS_CC);
+   zend_replace_error_handling(EH_THROW, NULL, error_handling TSRMLS_CC);
 
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, t|lS, 
filename, filename_len, filename_type, flags, encryption_key, 
encryption_key_len)) {
+   zend_restore_error_handling(error_handling TSRMLS_CC);
return;
}
 
+   zend_restore_error_handling(error_handling TSRMLS_CC);
+
if (db_obj-initialised) {
-   php_error_docref(NULL TSRMLS_CC, E_NOTICE, Already initialised 
DB Object);
+   zend_throw_exception(zend_exception_get_default(TSRMLS_C), 
Already initialised DB Object, 0 TSRMLS_CC);
+   return;
}
 
if (filename_type == IS_UNICODE) {
if (php_stream_path_encode(NULL, filename, filename_len, 
(UChar *)filename, filename_len, REPORT_ERRORS, FG(default_context)) == 
FAILURE) {
-   RETURN_FALSE;
+   
zend_throw_exception(zend_exception_get_default(TSRMLS_C), Unable to decode 
filepath, 0 TSRMLS_CC);
+   return;
}
}
 
if (strncmp(filename, :memory:, 8) != 0) {
if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
+   
zend_throw_exception(zend_exception_get_default(TSRMLS_C), Unable to expand 
filepath, 0 TSRMLS_CC);
if (filename_type == IS_UNICODE) {
efree(filename);
}
-   RETURN_FALSE;
+   return;
}
 
if (php_check_open_basedir(fullpath TSRMLS_CC)) {
+   
zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, 
open_basedir prohibits opening %s, fullpath);
if (filename_type == IS_UNICODE) {
efree(filename);
}
efree(fullpath);
-   RETURN_FALSE;
+   return;
}
} else {
fullpath = estrdup(filename);
@@ -119,7 +129,7 @@
/* Todo: utf-16 = sqlite3_open16 */
if (sqlite3_open(fullpath, (db_obj-db)) != SQLITE_OK) {
 #endif
-   php_error_docref(NULL TSRMLS_CC, E_NOTICE, Unable to open 
database: %s, sqlite3_errmsg(db_obj-db));
+   zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 
TSRMLS_CC, Unable to open database: %s, sqlite3_errmsg(db_obj-db));
if (fullpath) {
efree(fullpath);
}
@@ -131,6 +141,7 @@
 #if SQLITE_HAS_CODEC
if (encryption_key_len  0) {
if (sqlite3_key(db_obj-db, encryption_key, encryption_key_len) 
!= SQLITE_OK) {
+   
zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, 
Unable to open database: %s, sqlite3_errmsg(db_obj-db));
return;
}
}
@@ -143,7 +154,6 @@
if (fullpath) {
efree(fullpath);
}
-   RETURN_TRUE;
 }
 /* }}} */
 
http://cvs.php.net/viewvc.cgi/php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt?r1=1.2r2=1.3diff_format=u
Index: php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt
diff -u php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.2 
php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.3
--- php-src/ext/sqlite3/tests/sqlite3_15_open_error.phpt:1.2Fri Jul 25 
21:34:15 2008
+++ php-src/ext/sqlite3/tests/sqlite3_15_open_error.phptTue Feb 10 
00:44:09 2009
@@ -7,14 +7,14 @@
 $unreadable = dirname(__FILE__) . '/unreadable.db';
 touch($unreadable);
 chmod($unreadable,  0200);