com php-src: Removed "gc_" prefix.: Zend/tests/gc _037.phpt Zend/zend_builtin_functions.c Zen d/zend_gc.c Zend/zend_gc.h
| From: | Dmitry Stogov | Date: | Wed, 13 Jun 2018 08:28:24 +0000 |
| Subject: | com php-src: Removed "gc_" prefix.: Zend/tests/gc _037.phpt Zend/zend_builtin_functions.c Zen d/zend_gc.c Zend/zend_gc.h | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-102140@lists.php.net to get a copy of this message | ||
Commit: e788e8261ea8eb1b363377f1b185ac6b338607ed
Author: Dmitry Stogov <dmitry@zend.com> Wed, 13 Jun 2018 11:28:24 +0300
Parents: 2afc83732c1eb416acabace042eb0f5384bea721
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e788e8261ea8eb1b363377f1b185ac6b338607ed
Log:
Removed "gc_" prefix.
Changed paths:
M Zend/tests/gc_037.phpt
M Zend/zend_builtin_functions.c
M Zend/zend_gc.c
M Zend/zend_gc.h
Diff:
diff --git a/Zend/tests/gc_037.phpt b/Zend/tests/gc_037.phpt
index fc60bca..a1f33f0 100644
--- a/Zend/tests/gc_037.phpt
+++ b/Zend/tests/gc_037.phpt
@@ -13,18 +13,18 @@ gc_collect_cycles();
var_dump(gc_status());
--EXPECT--
array(3) {
- ["gc_runs"]=>
+ ["runs"]=>
int(0)
["collected"]=>
int(0)
- ["gc_threshold"]=>
+ ["threshold"]=>
int(10001)
}
array(3) {
- ["gc_runs"]=>
+ ["runs"]=>
int(1)
["collected"]=>
int(1)
- ["gc_threshold"]=>
+ ["threshold"]=>
int(10001)
}
diff --git a/Zend/zend_builtin_functions..c b/Zend/zend_builtin_functions.c
index feee2dd..c03eea8 100644
--- a/Zend/zend_builtin_functions.c
+++ b/Zend/zend_builtin_functions.c
@@ -398,9 +398,9 @@ ZEND_FUNCTION(gc_status)
array_init_size(return_value, 3);
- add_assoc_long_ex(return_value, "gc_runs", sizeof("gc_runs")-1,
(long)status.gc_runs);
+ add_assoc_long_ex(return_value, "runs", sizeof("runs")-1, (long)status.runs);
add_assoc_long_ex(return_value, "collected", sizeof("collected")-1,
(long)status.collected);
- add_assoc_long_ex(return_value, "gc_threshold", sizeof("gc_threshold")-1,
(long)status.gc_threshold);
+ add_assoc_long_ex(return_value, "threshold", sizeof("threshold")-1,
(long)status.threshold);
}
/* {{{ proto int func_num_args(void)
diff --git a/Zend/zend_gc.c b/Zend/zend_gc.c
index 3900837..69a24d4 100644
--- a/Zend/zend_gc.c
+++ b/Zend/zend_gc.c
@@ -1444,9 +1444,9 @@ ZEND_API int zend_gc_collect_cycles(void)
ZEND_API void zend_gc_get_status(zend_gc_status *status)
{
- status->gc_runs = GC_G(gc_runs);
+ status->runs = GC_G(gc_runs);
status->collected = GC_G(collected);
- status->gc_threshold = GC_G(gc_threshold);
+ status->threshold = GC_G(gc_threshold);
}
/*
diff --git a/Zend/zend_gc.h b/Zend/zend_gc.h
index f1bd7a7..57cdce4 100644
--- a/Zend/zend_gc.h
+++ b/Zend/zend_gc.h
@@ -25,9 +25,9 @@
BEGIN_EXTERN_C()
typedef struct _zend_gc_status {
- uint32_t gc_runs;
+ uint32_t runs;
uint32_t collected;
- uint32_t gc_threshold;
+ uint32_t threshold;
} zend_gc_status;
ZEND_API extern int (*gc_collect_cycles)(void);