[PHP-CVS] svn: /php/php-src/trunk/ext/mysqlnd/ mysqlnd_ps.c mysqlnd_result.c mysqlnd_structs.h mysqlnd_wireprotocol.c mysqlnd_wireprotocol.h

2011-03-21 Thread Andrey Hristov
andrey   Mon, 21 Mar 2011 13:58:11 +

Revision: http://svn.php.net/viewvc?view=revisionrevision=309494

Log:
throw out legacy code, that never was used for something
useful. Was added for QC but QC is now a plugin, not part of
the core.

Changed paths:
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_result.c
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_structs.h
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_wireprotocol.c
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_wireprotocol.h

Modified: php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c
===
--- php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c	2011-03-21 09:40:52 UTC (rev 309493)
+++ php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c	2011-03-21 13:58:11 UTC (rev 309494)
@@ -60,7 +60,6 @@
 	enum_func_status ret;
 	MYSQLND * conn;
 	MYSQLND_RES * result;
-	zend_bool to_cache = FALSE;

 	DBG_ENTER(mysqlnd_stmt::store_result);
 	if (!stmt || !stmt-conn || !stmt-result) {
@@ -99,10 +98,11 @@
 	result-type			= MYSQLND_RES_PS_BUF;
 	result-m.fetch_row		= mysqlnd_fetch_stmt_row_buffered;
 	result-m.fetch_lengths	= NULL;/* makes no sense */
+	result-m.row_decoder = php_mysqlnd_rowp_read_binary_protocol;

 	result-result_set_memory_pool = mysqlnd_mempool_create(MYSQLND_G(mempool_default_size) TSRMLS_CC);

-	ret = result-m.store_result_fetch_data(conn, result, result-meta, TRUE, to_cache TSRMLS_CC);
+	ret = result-m.store_result_fetch_data(conn, result, result-meta, TRUE TSRMLS_CC);

 	if (PASS == ret) {
 		/* libmysql API docs say it should be so for SELECT statements */
@@ -732,7 +732,6 @@
 current_row,
 meta-field_count,
 meta-fields,
-result-stored_data-persistent,
 result-conn-options.numeric_and_datetime_as_unicode,
 result-conn-options.int_and_float_native,
 result-conn-stats TSRMLS_CC);
@@ -852,7 +851,6 @@
 	result-unbuf-last_row_data,
 	row_packet-field_count,
 	row_packet-fields_metadata,
-	FALSE,
 	result-conn-options.numeric_and_datetime_as_unicode,
 	result-conn-options.int_and_float_native,
 	result-conn-stats TSRMLS_CC))
@@ -1037,7 +1035,6 @@
 	  result-unbuf-last_row_data,
 	  row_packet-field_count,
 	  row_packet-fields_metadata,
-	  FALSE,
 	  result-conn-options.numeric_and_datetime_as_unicode,
 	  result-conn-options.int_and_float_native,
 	  result-conn-stats TSRMLS_CC))

Modified: php/php-src/trunk/ext/mysqlnd/mysqlnd_result.c
===
--- php/php-src/trunk/ext/mysqlnd/mysqlnd_result.c	2011-03-21 09:40:52 UTC (rev 309493)
+++ php/php-src/trunk/ext/mysqlnd/mysqlnd_result.c	2011-03-21 13:58:11 UTC (rev 309494)
@@ -56,7 +56,6 @@
 	data_cursor,
 	result-meta-field_count,
 	result-meta-fields,
-	result-stored_data-persistent,
 	result-conn-options.numeric_and_datetime_as_unicode,
 	result-conn-options.int_and_float_native,
 	result-conn-stats TSRMLS_CC);
@@ -224,18 +223,18 @@

 		MYSQLND_INC_GLOBAL_STATISTIC_W_VALUE2(STAT_COPY_ON_WRITE_PERFORMED, copy_on_write_performed,
 			  STAT_COPY_ON_WRITE_SAVED, copy_on_write_saved);
-		mnd_pefree(set-data, set-persistent);
+		mnd_efree(set-data);
 		set-data = NULL;
 	}

 	if (set-row_buffers) {
-		mnd_pefree(set-row_buffers, set-persistent);
+		mnd_efree(set-row_buffers);
 		set-row_buffers	= NULL;
 	}
 	set-data_cursor = NULL;
 	set-row_count	= 0;

-	mnd_pefree(set, set-persistent);
+	mnd_efree(set);

 	DBG_VOID_RETURN;
 }
@@ -672,7 +671,6 @@
 		  result-unbuf-last_row_data,
 		  row_packet-field_count,
 		  row_packet-fields_metadata,
-		  FALSE,
 		  result-conn-options.numeric_and_datetime_as_unicode,
 		  result-conn-options.int_and_float_native,
 		  result-conn-stats TSRMLS_CC);
@@ -788,7 +786,6 @@
 			result-unbuf-last_row_data,
 			field_count,
 			row_packet-fields_metadata,
-			FALSE,
 			result-conn-options.numeric_and_datetime_as_unicode,
 			result-conn-options.int_and_float_native,
 			result-conn-stats TSRMLS_CC);
@@ -956,7 +953,6 @@
 			current_row,
 			result-meta-field_count,
 			result-meta-fields,
-			FALSE,
 			result-conn-options.numeric_and_datetime_as_unicode,
 			result-conn-options.int_and_float_native,
 			result-conn-stats TSRMLS_CC);
@@ -1030,7 +1026,6 @@
 			current_row,
 			result-meta-field_count,
 			result-meta-fields,
-			result-stored_data-persistent,
 			result-conn-options.numeric_and_datetime_as_unicode,
 			result-conn-options.int_and_float_native,
 			result-conn-stats TSRMLS_CC);
@@ -1112,8 +1107,7 @@

[PHP-CVS] svn: /php/php-src/trunk/ext/mysqlnd/ mysqlnd_ps.c

2011-03-18 Thread Andrey Hristov
andrey   Fri, 18 Mar 2011 13:55:25 +

Revision: http://svn.php.net/viewvc?view=revisionrevision=309384

Log:
WS

Changed paths:
U   php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c

Modified: php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c
===
--- php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c  2011-03-18 13:52:52 UTC (rev 
309383)
+++ php/php-src/trunk/ext/mysqlnd/mysqlnd_ps.c  2011-03-18 13:55:25 UTC (rev 
309384)
@@ -1305,7 +1305,6 @@
DBG_ERR(command out of sync);
DBG_RETURN(FAIL);
}
-
if (param_no = stmt-param_count) {
SET_STMT_ERROR(stmt, CR_INVALID_PARAMETER_NO, UNKNOWN_SQLSTATE, 
Invalid parameter number);
DBG_ERR(invalid param_no);
@@ -1424,8 +1423,7 @@
*/
for (i = 0; i  stmt-param_count; i++) {
/*
- We may have the last reference, then call 
zval_ptr_dtor()
- or we may leak memory.
+ We may have the last reference, then call 
zval_ptr_dtor() or we may leak memory.
  Switching from bind_one_parameter to 
bind_parameters may result in zv being NULL
*/
if (stmt-param_bind[i].zv) {
@@ -1918,6 +1916,7 @@
 }
 /* }}} */

+
 /* free_result() doesn't actually free stmt-result but only the buffers */
 /* {{{ mysqlnd_stmt::free_result */
 static enum_func_status

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