diff --git a/src/Symfony/Bundle/FrameworkBundle/Command/ServerCommand.php b/src/Symfony/Bundle/FrameworkBundle/Command/ServerCommand.php index acf71c666605a..3e1c324f00203 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Command/ServerCommand.php +++ b/src/Symfony/Bundle/FrameworkBundle/Command/ServerCommand.php @@ -54,7 +54,9 @@ protected function isOtherServerProcessRunning($address) return true; } - list($hostname, $port) = explode(':', $address); + $pos = strrpos($address, ':'); + $hostname = substr($address, 0, $pos); + $port = substr($address, $pos + 1); $fp = @fsockopen($hostname, $port, $errno, $errstr, 5);