diff options
author | Gwenael Gallon <gwenael.gallon@mac.com> | 2015-02-07 11:17:08 +0100 |
---|---|---|
committer | Gwenael Gallon <gwenael.gallon@mac.com> | 2015-02-07 11:17:08 +0100 |
commit | 19e1217db2e534d81abfd11fd4bed18516828bf8 (patch) | |
tree | b03842f04141e9c689c6a4831f0cd04eec7ddcc3 /system/database/drivers | |
parent | cb28c896fe883a373a906d5c6ef8c71c0b2ae999 (diff) |
Fix unreachable code
Diffstat (limited to 'system/database/drivers')
-rw-r--r-- | system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php | 10 | ||||
-rw-r--r-- | system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php b/system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php index c8d7c770d..09b48f124 100644 --- a/system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php +++ b/system/database/drivers/pdo/subdrivers/pdo_dblib_driver.php @@ -154,17 +154,17 @@ class CI_DB_pdo_dblib_driver extends CI_DB_pdo_driver { */ protected function _list_tables($prefix_limit = FALSE) { - return 'SELECT '.$this->escape_identifiers('name') - .' FROM '.$this->escape_identifiers('sysobjects') - .' WHERE '.$this->escape_identifiers('type')." = 'U'"; + $sql = 'SELECT '.$this->escape_identifiers('name') + .' FROM '.$this->escape_identifiers('sysobjects') + .' WHERE '.$this->escape_identifiers('type')." = 'U'"; if ($prefix_limit === TRUE && $this->dbprefix !== '') { $sql .= ' AND '.$this->escape_identifiers('name')." LIKE '".$this->escape_like_str($this->dbprefix)."%' " - .sprintf($this->_like_escape_str, $this->_like_escape_chr); + .sprintf($this->_like_escape_str, $this->_like_escape_chr); } - return $sql.' ORDER BY '.$this->escape_identifiers('name'); + return $sql .= ' ORDER BY '.$this->escape_identifiers('name'); } // -------------------------------------------------------------------- diff --git a/system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php b/system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php index b5bdbf91a..d366d119c 100644 --- a/system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php +++ b/system/database/drivers/pdo/subdrivers/pdo_sqlsrv_driver.php @@ -183,17 +183,17 @@ class CI_DB_pdo_sqlsrv_driver extends CI_DB_pdo_driver { */ protected function _list_tables($prefix_limit = FALSE) { - return 'SELECT '.$this->escape_identifiers('name') - .' FROM '.$this->escape_identifiers('sysobjects') - .' WHERE '.$this->escape_identifiers('type')." = 'U'"; + $sql = 'SELECT '.$this->escape_identifiers('name') + .' FROM '.$this->escape_identifiers('sysobjects') + .' WHERE '.$this->escape_identifiers('type')." = 'U'"; if ($prefix_limit === TRUE && $this->dbprefix !== '') { $sql .= ' AND '.$this->escape_identifiers('name')." LIKE '".$this->escape_like_str($this->dbprefix)."%' " - .sprintf($this->_like_escape_str, $this->_like_escape_chr); + .sprintf($this->_like_escape_str, $this->_like_escape_chr); } - return $sql.' ORDER BY '.$this->escape_identifiers('name'); + return $sql .= ' ORDER BY '.$this->escape_identifiers('name'); } // -------------------------------------------------------------------- |