summaryrefslogtreecommitdiff
path: root/ext/pdo_sqlite
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/pdo_sqlite
parent98a2c03808f73be0c08bfe654b985483ccb8d6bc (diff)
downloadphp-git-8146078f7bbbe4f4799e1a154ea450c90c855728.tar.gz
Improved memory usage by movig constants to read only memory. (Dmitry, Pierre)
Diffstat (limited to 'ext/pdo_sqlite')
-rw-r--r--ext/pdo_sqlite/pdo_sqlite.c4
-rw-r--r--ext/pdo_sqlite/sqlite_driver.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/ext/pdo_sqlite/pdo_sqlite.c b/ext/pdo_sqlite/pdo_sqlite.c
index 937f401159..f7a58daa67 100644
--- a/ext/pdo_sqlite/pdo_sqlite.c
+++ b/ext/pdo_sqlite/pdo_sqlite.c
@@ -34,7 +34,7 @@
#define PHP_PDO_SQLITE_MODULE_VERSION "1.0.1"
/* {{{ pdo_sqlite_functions[] */
-zend_function_entry pdo_sqlite_functions[] = {
+const zend_function_entry pdo_sqlite_functions[] = {
{NULL, NULL, NULL}
};
/* }}} */
@@ -42,7 +42,7 @@ zend_function_entry pdo_sqlite_functions[] = {
/* {{{ pdo_sqlite_deps
*/
#if ZEND_MODULE_API_NO >= 20050922
-static zend_module_dep pdo_sqlite_deps[] = {
+static const zend_module_dep pdo_sqlite_deps[] = {
ZEND_MOD_REQUIRED("pdo")
{NULL, NULL, NULL}
};
diff --git a/ext/pdo_sqlite/sqlite_driver.c b/ext/pdo_sqlite/sqlite_driver.c
index d06559ea8a..5afb51d9cf 100644
--- a/ext/pdo_sqlite/sqlite_driver.c
+++ b/ext/pdo_sqlite/sqlite_driver.c
@@ -609,13 +609,13 @@ static PHP_METHOD(SQLite, sqliteCreateAggregate)
RETURN_FALSE;
}
/* }}} */
-static zend_function_entry dbh_methods[] = {
+static const zend_function_entry dbh_methods[] = {
PHP_ME(SQLite, sqliteCreateFunction, NULL, ZEND_ACC_PUBLIC)
PHP_ME(SQLite, sqliteCreateAggregate, NULL, ZEND_ACC_PUBLIC)
{NULL, NULL, NULL}
};
-static zend_function_entry *get_driver_methods(pdo_dbh_t *dbh, int kind TSRMLS_DC)
+static const zend_function_entry *get_driver_methods(pdo_dbh_t *dbh, int kind TSRMLS_DC)
{
switch (kind) {
case PDO_DBH_DRIVER_METHOD_KIND_DBH: