Skip to content

Commit

Permalink
Small Travis CI build fix (#4165).
Browse files Browse the repository at this point in the history
  • Loading branch information
Joe136 committed Sep 4, 2014
1 parent 3e25658 commit 57d775e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libraries/joomla/database/driver/postgresql.php
Expand Up @@ -85,6 +85,8 @@ public function __construct( $options )
* pg_connect() takes the host and port as separate arguments. Therefore, we
* have to extract them from the host string.
*/
$port = false;

if (preg_match('/^(?P<host>((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))(:(?P<port>.+))?$/', $options['host'], $matches))
{
// It's an IPv4 address with or without port
Expand Down

0 comments on commit 57d775e

Please sign in to comment.