From: Aaron Schulz Date: Sun, 16 Jun 2019 23:20:55 +0000 (+0100) Subject: rdbms: do not close the connection in LoadBalancerSingle::__destruct X-Git-Tag: 1.34.0-rc.0~1387^2 X-Git-Url: http://git.cyclocoop.org/%22%2C%20generer_url_ecrire%28?a=commitdiff_plain;h=143333b172cd6c5465a92493a40ad423feb5f366;p=lhc%2Fweb%2Fwiklou.git rdbms: do not close the connection in LoadBalancerSingle::__destruct The connection instance is injected unlike with the parent class, meaning that it does not own the connection. No-op the method. Change-Id: I61914b986619f201ac9cc8c94d46873a3b9e8177 --- diff --git a/includes/libs/rdbms/loadbalancer/LoadBalancerSingle.php b/includes/libs/rdbms/loadbalancer/LoadBalancerSingle.php index fcddfcf139..4c68833e7e 100644 --- a/includes/libs/rdbms/loadbalancer/LoadBalancerSingle.php +++ b/includes/libs/rdbms/loadbalancer/LoadBalancerSingle.php @@ -86,6 +86,10 @@ class LoadBalancerSingle extends LoadBalancer { protected function reallyOpenConnection( array $server, DatabaseDomain $domain ) { return $this->db; } + + public function __destruct() { + // do nothing since the connection was injected + } } /**