From ef3b9225fd9e3416da471824d9f6d5f57a6642dd Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Sun, 27 Mar 2005 18:06:44 +0000 Subject: [PATCH] Fixed bug causing transactions to not be started all the time --- includes/LoadBalancer.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/includes/LoadBalancer.php b/includes/LoadBalancer.php index f5fdf6175e..8c9aa64f55 100644 --- a/includes/LoadBalancer.php +++ b/includes/LoadBalancer.php @@ -402,7 +402,8 @@ class LoadBalancer { function closeAll() { foreach( $this->mConnections as $i => $conn ) { if ( $this->isOpen( $i ) ) { - $conn->close(); + // Need to use this syntax because $conn is a copy not a reference + $this->mConnections[$i]->close(); } } } @@ -410,7 +411,8 @@ class LoadBalancer { function commitAll() { foreach( $this->mConnections as $i => $conn ) { if ( $this->isOpen( $i ) ) { - $conn->immediateCommit(); + // Need to use this syntax because $conn is a copy not a reference + $this->mConnections[$i]->immediateCommit(); } } } -- 2.20.1