Commit 2ce7cd5a authored by anarcat's avatar anarcat Committed by anarcat

enforce a valid port in configuration files

parent 13b761e3
......@@ -91,7 +91,7 @@ function _provision_apache_delete_vhost_config($url) {
function _provision_apache_create_vhost_config($url, $template = NULL) {
$options = drush_get_merged_options();
// backward compatibility with 0.3
if (!$options['site_port']) {
if (!$options['site_port'] || $options['site_port'] < 1 || $options['site_port'] > 66535) {
$options['site_port'] = 80;
}
if (is_null($template)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment