--- evolution-2.30.3.orig/plugins/webdav-account-setup/webdav-contacts-source.c
+++ evolution-2.30.3/plugins/webdav-account-setup/webdav-contacts-source.c
@@ -123,8 +123,12 @@ set_ui_from_source(ui_data *data)
 	gtk_toggle_button_set_active(data->avoid_ifmatch_toggle, avoid_ifmatch);
 
 	/* it's really a http or https protocol */
-	if (suri)
+	if (suri) {
+        /* soup_uri_set_scheme reset the port if it was specified by the user. */
+        guint port = suri->port;
 		soup_uri_set_scheme (suri, use_ssl ? "https" : "http");
+        soup_uri_set_port(suri, port);
+    }
 
 	/* remove user/username and set user field */
 	if (suri && suri->user != NULL) {
