aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/db/mysql4.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/db/mysql4.php')
-rw-r--r--phpBB/includes/db/mysql4.php31
1 files changed, 16 insertions, 15 deletions
diff --git a/phpBB/includes/db/mysql4.php b/phpBB/includes/db/mysql4.php
index ac896ce78f..26da6432c1 100644
--- a/phpBB/includes/db/mysql4.php
+++ b/phpBB/includes/db/mysql4.php
@@ -67,22 +67,22 @@ class dbal_mysql4 extends dbal
case 'begin':
$result = @mysql_query('BEGIN', $this->db_connect_id);
$this->transaction = true;
- break;
+ break;
case 'commit':
$result = @mysql_query('COMMIT', $this->db_connect_id);
$this->transaction = false;
-
+
if (!$result)
{
@mysql_query('ROLLBACK', $this->db_connect_id);
}
- break;
+ break;
case 'rollback':
$result = @mysql_query('ROLLBACK', $this->db_connect_id);
$this->transaction = false;
- break;
+ break;
default:
$result = true;
@@ -148,10 +148,10 @@ class dbal_mysql4 extends dbal
* Build LIMIT query
*/
function sql_query_limit($query, $total, $offset = 0, $cache_ttl = 0)
- {
- if ($query != '')
+ {
+ if ($query != '')
{
- $this->query_result = false;
+ $this->query_result = false;
// if $total is set to 0 we do not want to limit the number of rows
if ($total == 0)
@@ -162,12 +162,12 @@ class dbal_mysql4 extends dbal
$query .= "\n LIMIT " . ((!empty($offset)) ? $offset . ', ' . $total : $total);
- return $this->sql_query($query, $cache_ttl);
- }
- else
- {
- return false;
- }
+ return $this->sql_query($query, $cache_ttl);
+ }
+ else
+ {
+ return false;
+ }
}
/**
@@ -289,7 +289,7 @@ class dbal_mysql4 extends dbal
{
return @mysql_real_escape_string($msg);
}
-
+
return @mysql_real_escape_string($msg, $this->db_connect_id);
}
@@ -305,6 +305,7 @@ class dbal_mysql4 extends dbal
$data = '(' . $data . ')';
break;
}
+
return $data;
}
@@ -321,7 +322,7 @@ class dbal_mysql4 extends dbal
'code' => @mysql_errno()
);
}
-
+
return array(
'message' => @mysql_error($this->db_connect_id),
'code' => @mysql_errno($this->db_connect_id)