From: Adam Dickmeiss Date: Fri, 28 Dec 2012 14:11:42 +0000 (+0100) Subject: Only add http:// for SRU if not already there X-Git-Tag: v1.6.24~7 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=71b10adee4c11891aa2283bf844c564bc06f3177;p=pazpar2-moved-to-github.git Only add http:// for SRU if not already there This is to allow https or other method to be given. Similar to MP-425. --- diff --git a/src/connection.c b/src/connection.c index d3eaeef..c1ff7d5 100644 --- a/src/connection.c +++ b/src/connection.c @@ -463,12 +463,11 @@ static int connection_connect(struct connection *con, iochan_man_t iochan_man) return -1; } - if (sru && *sru) + if (sru && *sru && !strstr(host->url, "://")) { char http_hostport[512]; strcpy(http_hostport, "http://"); strcat(http_hostport, host->url); - yaz_log(YLOG_LOG, "SRU connect to : %s", http_hostport); ZOOM_connection_connect(con->link, http_hostport, 0); } else