Aleksander Machniak
2013-04-30 410a4c663e10b10e48bf3d09d4a100e43ce1e12a
Inlcude SQL query in the log on SQL error (#1489064)
2 files modified
12 ■■■■■ changed files
CHANGELOG 1 ●●●● patch | view | raw | blame | history
program/lib/Roundcube/rcube_db.php 11 ●●●● patch | view | raw | blame | history
CHANGELOG
@@ -1,6 +1,7 @@
CHANGELOG Roundcube Webmail
===========================
- Inlcude SQL query in the log on SQL error (#1489064)
- Fix handling untagged responses in IMAP FETCH - "could not load message" error (#1489074)
- Fix very small window size in Chrome (#1488931)
- Fix list page reset when viewing a message in Larry skin (#1489076)
program/lib/Roundcube/rcube_db.php
@@ -405,21 +405,22 @@
        $this->db_error_msg = null;
        // send query
        $query = $this->dbh->query($query);
        $result = $this->dbh->query($query);
        if ($query === false) {
        if ($result === false) {
            $error = $this->dbh->errorInfo();
            $this->db_error = true;
            $this->db_error_msg = sprintf('[%s] %s', $error[1], $error[2]);
            rcube::raise_error(array('code' => 500, 'type' => 'db',
                'line' => __LINE__, 'file' => __FILE__,
                'message' => $this->db_error_msg), true, false);
                'message' => $this->db_error_msg . " (SQL Query: $query)"
                ), true, false);
        }
        $this->last_result = $query;
        $this->last_result = $result;
        return $query;
        return $result;
    }
    /**