Skip to content
This repository
Browse code

Merge pull request #12 from ecaron/master

Fix incorrect logging when a reconnect occurs
  • Loading branch information...
commit 20dbc34300a264e77866ca75cbdcaa9f42e01e7c 2 parents 7705ddf + 704ccca
Eric Caron ecaron authored

Showing 1 changed file with 5 additions and 3 deletions. Show diff stats Hide diff stats

  1. +5 3 processor.php
8 processor.php
@@ -166,9 +166,11 @@
166 166 //Make sure our connection is still active, otherwise reconnect
167 167 $query = $connection->query("SELECT NOW()");
168 168 if ($query === false) {
169   - $connection->real_connect($host, $user, $pass);
170   - logError("[$iniFile] Connection error on $database\n\t"
171   - . $connection->error);
  169 + if ($connection->real_connect($host, $user, $pass) === false) {
  170 + logError("[$iniFile] Connection error on $database\n\t"
  171 + . $connection->error);
  172 + continue;
  173 + }
172 174 }
173 175
174 176 $databaseSuccess = true;

0 comments on commit 20dbc34

Please sign in to comment.
Something went wrong with that request. Please try again.