summaryrefslogtreecommitdiff
path: root/ext/date/php_date.c
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2007-09-27 18:28:44 +0000
committerDmitry Stogov <dmitry@php.net>2007-09-27 18:28:44 +0000
commit8146078f7bbbe4f4799e1a154ea450c90c855728 (patch)
tree46cb160985407d24ff3a9d485a90e88fee4cdbb6 /ext/date/php_date.c
parent98a2c03808f73be0c08bfe654b985483ccb8d6bc (diff)
downloadphp-git-8146078f7bbbe4f4799e1a154ea450c90c855728.tar.gz
Improved memory usage by movig constants to read only memory. (Dmitry, Pierre)
Diffstat (limited to 'ext/date/php_date.c')
-rw-r--r--ext/date/php_date.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/date/php_date.c b/ext/date/php_date.c
index 930cec6f1f..69187dd956 100644
--- a/ext/date/php_date.c
+++ b/ext/date/php_date.c
@@ -149,7 +149,7 @@ ZEND_END_ARG_INFO()
/* }}} */
/* {{{ Function table */
-zend_function_entry date_functions[] = {
+const zend_function_entry date_functions[] = {
PHP_FE(strtotime, arginfo_strtotime)
PHP_FE(date, arginfo_date)
PHP_FE(idate, arginfo_idate)
@@ -201,7 +201,7 @@ zend_function_entry date_functions[] = {
};
-zend_function_entry date_funcs_date[] = {
+const zend_function_entry date_funcs_date[] = {
PHP_ME(DateTime, __construct, NULL, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC)
PHP_ME_MAPPING(format, date_format, NULL, 0)
PHP_ME_MAPPING(modify, date_modify, NULL, 0)
@@ -214,7 +214,7 @@ zend_function_entry date_funcs_date[] = {
{NULL, NULL, NULL}
};
-zend_function_entry date_funcs_timezone[] = {
+const zend_function_entry date_funcs_timezone[] = {
PHP_ME(DateTimeZone, __construct, NULL, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC)
PHP_ME_MAPPING(getName, timezone_name_get, NULL, 0)
PHP_ME_MAPPING(getOffset, timezone_offset_get, NULL, 0)
@@ -305,7 +305,7 @@ static int date_object_compare_date(zval *d1, zval *d2 TSRMLS_DC);
static zend_object_value date_object_clone_timezone(zval *this_ptr TSRMLS_DC);
/* This is need to ensure that session extension request shutdown occurs 1st, because it uses the date extension */
-static zend_module_dep date_deps[] = {
+static const zend_module_dep date_deps[] = {
ZEND_MOD_OPTIONAL("session")
{NULL, NULL, NULL}
};