diff options
author | Andrey Hristov <andrey@php.net> | 2014-01-29 15:32:02 +0200 |
---|---|---|
committer | Andrey Hristov <andrey@php.net> | 2014-01-29 15:32:02 +0200 |
commit | 1c7f54d4f7fe58f1d2c7ed00ca80d93dddc265ab (patch) | |
tree | b981a37d3072a193d0fe9791fc75d3b3b83208f2 /ext/mysqli/mysqli_nonapi.c | |
parent | fb5c7cda5d776a84730c5133f27e72cb427f22ae (diff) | |
parent | 253a66c8d56e72b166b2d8ebfbc4b368eed4a9fb (diff) | |
download | php-git-1c7f54d4f7fe58f1d2c7ed00ca80d93dddc265ab.tar.gz |
Merge branch 'PHP-5.6'
Conflicts:
NEWS
ext/openssl/xp_ssl.c
Diffstat (limited to 'ext/mysqli/mysqli_nonapi.c')
-rw-r--r-- | ext/mysqli/mysqli_nonapi.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index db0352baeb..312f2806ce 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -1207,6 +1207,23 @@ PHP_FUNCTION(mysqli_release_savepoint) /* }}} */ +/* {{{ proto bool mysqli_get_links_stats() + Returns information about open and cached links */ +PHP_FUNCTION(mysqli_get_links_stats) +{ + if (ZEND_NUM_ARGS()) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "no parameters expected"); + return; + } + array_init(return_value); + add_assoc_long_ex(return_value, "total", sizeof("total"), MyG(num_links)); + add_assoc_long_ex(return_value, "active_plinks", sizeof("active_plinks"), MyG(num_active_persistent)); + add_assoc_long_ex(return_value, "cached_plinks", sizeof("cached_plinks"), MyG(num_inactive_persistent)); +} +/* }}} */ + + + /* * Local variables: * tab-width: 4 |