diff options
author | Nikita Popov <nikic@php.net> | 2016-01-30 14:56:17 +0100 |
---|---|---|
committer | Nikita Popov <nikic@php.net> | 2016-01-30 15:35:28 +0100 |
commit | 93dc91b386b53bdd317ea6abd70640e2bbfbaf73 (patch) | |
tree | d41b6d2baf80da77c154a4174634d6728e86bb31 /ext/sqlite3/sqlite3.c | |
parent | 2eb4728611ac9ff6aa77fece737470beabe1db62 (diff) | |
download | php-git-93dc91b386b53bdd317ea6abd70640e2bbfbaf73.tar.gz |
Remove version checks
PHP_VERSION_ID
PHP_API_VERSION
ZEND_MODULE_API_NO
PHP_MAJOR_VERSION, PHP_MINOR_VERSION
ZEND_ENGINE_2
I've left litespeed alone, as it seems to genuinely maintain support
for many PHP versions.
Diffstat (limited to 'ext/sqlite3/sqlite3.c')
-rw-r--r-- | ext/sqlite3/sqlite3.c | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index 6f2656ab51..5526cf603c 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -123,14 +123,6 @@ PHP_METHOD(sqlite3, open) return; } -#if PHP_API_VERSION < 20100412 - if (PG(safe_mode) && (!php_checkuid(fullpath, NULL, CHECKUID_CHECK_FILE_AND_DIR))) { - zend_throw_exception_ex(zend_ce_exception, 0, "safe_mode prohibits opening %s", fullpath); - efree(fullpath); - return; - } -#endif - if (php_check_open_basedir(fullpath)) { zend_throw_exception_ex(zend_ce_exception, 0, "open_basedir prohibits opening %s", fullpath); efree(fullpath); @@ -163,11 +155,7 @@ PHP_METHOD(sqlite3, open) db_obj->initialised = 1; -#if PHP_API_VERSION < 20100412 - if (PG(safe_mode) || (PG(open_basedir) && *PG(open_basedir))) { -#else if (PG(open_basedir) && *PG(open_basedir)) { -#endif sqlite3_set_authorizer(db_obj->db, php_sqlite3_authorizer, NULL); } @@ -1980,13 +1968,6 @@ static int php_sqlite3_authorizer(void *autharg, int access_type, const char *ar case SQLITE_ATTACH: { if (memcmp(arg3, ":memory:", sizeof(":memory:")) && *arg3) { - -#if PHP_API_VERSION < 20100412 - if (PG(safe_mode) && (!php_checkuid(arg3, NULL, CHECKUID_CHECK_FILE_AND_DIR))) { - return SQLITE_DENY; - } -#endif - if (php_check_open_basedir(arg3)) { return SQLITE_DENY; } |