zak Wed Oct 9 09:46:19 2002 EDT Modified files: /php4/ext/mysql php_mysql.c Log: Removed spurious code. Thanks Derick Index: php4/ext/mysql/php_mysql.c diff -u php4/ext/mysql/php_mysql.c:1.166 php4/ext/mysql/php_mysql.c:1.167 --- php4/ext/mysql/php_mysql.c:1.166 Wed Oct 9 09:05:42 2002 +++ php4/ext/mysql/php_mysql.c Wed Oct 9 09:46:18 2002 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_mysql.c,v 1.166 2002/10/09 13:05:42 zak Exp $ */ +/* $Id: php_mysql.c,v 1.167 2002/10/09 13:46:18 zak Exp $ */ /* TODO: * @@ -229,7 +229,6 @@ static int _restore_connection_defaults(zend_rsrc_list_entry *rsrc TSRMLS_DC) { php_mysql_conn *link; - char query[17]; /* Increase size if query length increases */ char user[128]; char passwd[128]; @@ -252,14 +251,10 @@ } /* rollback possible transactions */ - memcpy(query, "ROLLBACK", sizeof("ROLLBACK")); - /* Binary safe query not required here */ - mysql_query(&link->conn, query); - - /* restore session variable "autocommit" to default (=1) */ - memcpy(query, "SET AUTOCOMMIT=1", sizeof("SET AUTOCOMMIT=1")); - /* Binary safe query not required here */ - mysql_query(&link->conn, query); + mysql_query(&link->conn, "ROLLBACK"); + + /* restore session variable "autocommit" to default (1) */ + mysql_query(&link->conn, "SET AUTOCOMMIT=1"); /* unset the current selected db */ #if MYSQL_VERSION_ID > 32329
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php