From aed4b086acaa50318b3e91146a35a9af6f46e11d Mon Sep 17 00:00:00 2001 From: Kalle Sommer Nielsen Date: Wed, 18 Dec 2013 09:32:26 +0100 Subject: Eliminate the TSRMLS_FETCH() calls in the ticks functions and hook --- main/php_ticks.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'main/php_ticks.c') diff --git a/main/php_ticks.c b/main/php_ticks.c index 17ffb9c770..c65fc3246c 100644 --- a/main/php_ticks.c +++ b/main/php_ticks.c @@ -46,17 +46,13 @@ static int php_compare_tick_functions(void *elem1, void *elem2) return (func1 == func2); } -PHPAPI void php_add_tick_function(void (*func)(int)) +PHPAPI void php_add_tick_function(void (*func)(int) TSRMLS_DC) { - TSRMLS_FETCH(); - zend_llist_add_element(&PG(tick_functions), (void *)&func); } -PHPAPI void php_remove_tick_function(void (*func)(int)) +PHPAPI void php_remove_tick_function(void (*func)(int) TSRMLS_DC) { - TSRMLS_FETCH(); - zend_llist_del_element(&PG(tick_functions), (void *)func, (int(*)(void*, void*))php_compare_tick_functions); } @@ -69,10 +65,8 @@ static void php_tick_iterator(void *data, void *arg TSRMLS_DC) func(*((int *)arg)); } -void php_run_ticks(int count) +void php_run_ticks(int count TSRMLS_DC) { - TSRMLS_FETCH(); - zend_llist_apply_with_argument(&PG(tick_functions), (llist_apply_with_arg_func_t) php_tick_iterator, &count TSRMLS_CC); } -- cgit v1.2.1 From c081ce628f0d76d44784d7bb8e06428b06142ac0 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 3 Jan 2014 11:08:10 +0800 Subject: Bump year --- main/php_ticks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/php_ticks.c') diff --git a/main/php_ticks.c b/main/php_ticks.c index 17ffb9c770..b07f925fab 100644 --- a/main/php_ticks.c +++ b/main/php_ticks.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2013 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 | -- cgit v1.2.1 From d0cb715373c3fbe9dc095378ec5ed8c71f799f67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Fri, 19 Sep 2014 18:33:14 +0200 Subject: s/PHP 5/PHP 7/ --- main/php_ticks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/php_ticks.c') diff --git a/main/php_ticks.c b/main/php_ticks.c index 248b5a9e04..daa6cde6ff 100644 --- a/main/php_ticks.c +++ b/main/php_ticks.c @@ -1,6 +1,6 @@ /* +----------------------------------------------------------------------+ - | PHP Version 5 | + | PHP Version 7 | +----------------------------------------------------------------------+ | Copyright (c) 1997-2014 The PHP Group | +----------------------------------------------------------------------+ -- cgit v1.2.1