--- embedaddon/php/ext/mysql/php_mysql.c 2012/05/29 12:34:41 1.1.1.2 +++ embedaddon/php/ext/mysql/php_mysql.c 2014/06/15 20:03:51 1.1.1.5 @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2014 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_mysql.c,v 1.1.1.2 2012/05/29 12:34:41 misho Exp $ */ +/* $Id: php_mysql.c,v 1.1.1.5 2014/06/15 20:03:51 misho Exp $ */ /* TODO: * @@ -296,7 +296,7 @@ static const zend_function_entry mysql_functions[] = { #ifdef MYSQL_HAS_SET_CHARSET PHP_FE(mysql_set_charset, arginfo_mysql_set_charset) #endif - /* for downwards compatability */ + /* for downwards compatibility */ PHP_FALIAS(mysql, mysql_db_query, arginfo_mysql_db_query) PHP_FALIAS(mysql_fieldname, mysql_field_name, arginfo_mysql_field_name) PHP_FALIAS(mysql_fieldtable, mysql_field_table, arginfo_mysql_field_seek) @@ -720,7 +720,7 @@ PHP_MINFO_FUNCTION(mysql) static void php_mysql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) { char *user=NULL, *passwd=NULL, *host_and_port=NULL, *socket=NULL, *tmp=NULL, *host=NULL; - int user_len, passwd_len, host_len; + int user_len = 0, passwd_len = 0, host_len = 0; char *hashed_details=NULL; int hashed_details_length, port = MYSQL_PORT; long client_flags = 0; @@ -1918,7 +1918,7 @@ PHP_FUNCTION(mysql_result) /* johannes TODO: -Do 2 zend_parse_paramters calls instead of type "z" and switch below +Do 2 zend_parse_parameters calls instead of type "z" and switch below Q: String or long first? */ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl|z", &result, &row, &field) == FAILURE) {