mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 22:10:45 +02:00
[ticket/15243] Check permissions before installing with SQLite
PHPBB3-15243
This commit is contained in:
@@ -336,6 +336,15 @@ class database
|
||||
);
|
||||
}
|
||||
|
||||
// Check if SQLite database is writable
|
||||
if ($dbms_info['SCHEMA'] === 'sqlite'
|
||||
&& (!$this->filesystem->is_writable($dbhost) || !$this->filesystem->is_writable(pathinfo($dbhost, PATHINFO_DIRNAME))))
|
||||
{
|
||||
$errors[] = array(
|
||||
'title' =>'INST_ERR_DB_NO_WRITABLE',
|
||||
);
|
||||
}
|
||||
|
||||
// Try to connect to db
|
||||
if (is_array($db->sql_connect($dbhost, $dbuser, $dbpass, $dbname, $dbport, false, true)))
|
||||
{
|
||||
|
Reference in New Issue
Block a user