Opened 4 years ago
Closed 4 years ago
#1485772 closed Bugs (fixed)
db.inc.php 'db_dsnw' mode parameter for sqlite is ignored
| Reported by: | cpanelphil | Owned by: | |
|---|---|---|---|
| Priority: | 5 | Milestone: | 0.2.2 |
| Component: | Database | Version: | 0.2.1 |
| Severity: | normal | Keywords: | sqlite mode |
| Cc: |
Description
Hi all,
The 'db_dsnw' attribute on sqlite connection strings is silently thrown away within MDB2.php's 'function parseDSN'.
Steps to replicate in current version (0.2.1):
1) $rcmail_configdb_dsnw? = 'sqlite:///tmp/roundcube.db?mode=0600' in db.inc.php.
2) MDB2.php skips over this conditional where $key = 'mode':
if (!isset($parsed[$key])) {
3) Because $GLOBALS_MDB2_dsninfo_default? is assigned default values at the top of the MDB2.php file.
4) Which are slurped into the $parsed array at the top of the parseDSN function.
Result: the 'mode' attribute within a sqlite connection string is ignored.
Change History (1)
comment:1 Changed 4 years ago by alec
- Milestone changed from later to 0.2.2
- Resolution set to fixed
- Status changed from new to closed
Note: See
TracTickets for help on using
tickets.

https://pear.php.net/bugs/bug.php?id=16020. Fixed in [200b162b].