Skip to content

Commit e6ad856

Browse files
Indrani SonawaneIndrani Sonawane
authored andcommitted
Merge remote-tracking branch '38842/task/fixing-static-compilation' into augcommpr
2 parents 1c2ed4d + f050273 commit e6ad856

File tree

1 file changed

+6
-0
lines changed
  • lib/internal/Magento/Framework/DB/Adapter/Pdo

1 file changed

+6
-0
lines changed

lib/internal/Magento/Framework/DB/Adapter/Pdo/Mysql.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -439,6 +439,12 @@ private function avoidReusingParentProcessConnection()
439439
$this->parentConnections[] = $this->_connection;
440440
$this->_connection = null;
441441
$this->pid = getmypid();
442+
443+
// Reset config host to avoid issue with multiple connections
444+
if (!empty($this->_config['port']) && strpos($this->_config['host'], ':') === false) {
445+
$this->_config['host'] = implode(':', [$this->_config['host'], $this->_config['port']]);
446+
unset($this->_config['port']);
447+
}
442448
}
443449
}
444450

0 commit comments

Comments
 (0)