diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2010-01-31 19:18:56 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2010-01-31 19:18:56 +0000 |
commit | 6616ceaefae211876b3f31b0b404f4172a5a311e (patch) | |
tree | 9cbe75e2eb3221c1bef29e330e376f1c996965ec /ext/pdo_mysql/pdo_mysql.c | |
parent | dff4e7fda131f3f25204d7f6e2e549731bedad88 (diff) | |
download | php-git-6616ceaefae211876b3f31b0b404f4172a5a311e.tar.gz |
Fixed crash in ZTS mode due to ini values not being initialized
Diffstat (limited to 'ext/pdo_mysql/pdo_mysql.c')
-rwxr-xr-x | ext/pdo_mysql/pdo_mysql.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index 542168539f..eaaba2da12 100755 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -115,12 +115,11 @@ static PHP_MINFO_FUNCTION(pdo_mysql) /* }}} */ -#if PDO_USE_MYSQLND +#if PDO_USE_MYSQLND && PDO_DBG_ENABLED /* {{{ PHP_RINIT_FUNCTION */ static PHP_RINIT_FUNCTION(pdo_mysql) { -#if PDO_DBG_ENABLED if (PDO_MYSQL_G(debug)) { MYSQLND_DEBUG *dbg = mysqlnd_debug_init(mysqlnd_debug_std_no_trace_funcs TSRMLS_CC); if (!dbg) { @@ -129,18 +128,15 @@ static PHP_RINIT_FUNCTION(pdo_mysql) dbg->m->set_mode(dbg, PDO_MYSQL_G(debug)); PDO_MYSQL_G(dbg) = dbg; } -#endif return SUCCESS; } /* }}} */ - /* {{{ PHP_RSHUTDOWN_FUNCTION */ static PHP_RSHUTDOWN_FUNCTION(pdo_mysql) { -#if PDO_DBG_ENABLED MYSQLND_DEBUG *dbg = PDO_MYSQL_G(dbg); PDO_DBG_ENTER("RSHUTDOWN"); if (dbg) { @@ -148,11 +144,11 @@ static PHP_RSHUTDOWN_FUNCTION(pdo_mysql) dbg->m->free_handle(dbg); PDO_MYSQL_G(dbg) = NULL; } -#endif + return SUCCESS; } /* }}} */ - +#endif /* {{{ PHP_GINIT_FUNCTION */ @@ -167,8 +163,6 @@ static PHP_GINIT_FUNCTION(pdo_mysql) #endif } /* }}} */ -#endif - /* {{{ pdo_mysql_functions[] */ const zend_function_entry pdo_mysql_functions[] = { @@ -205,15 +199,11 @@ zend_module_entry pdo_mysql_module_entry = { #endif PHP_MINFO(pdo_mysql), "1.0.2", -#if PDO_USE_MYSQLND PHP_MODULE_GLOBALS(pdo_mysql), PHP_GINIT(pdo_mysql), NULL, NULL, STANDARD_MODULE_PROPERTIES_EX -#else - STANDARD_MODULE_PROPERTIES -#endif }; /* }}} */ |