2016-06-17 Fred Gleason <fredg@paravelsystems.com>

* Fixed a bug in 'lib/rddownload.cpp' that caused download URLs
	using 'https' protocol to fail to be properly escaped.
This commit is contained in:
Fred Gleason
2016-06-17 14:06:19 -04:00
parent f04fa15090
commit ec79802cb6
3 changed files with 9 additions and 4 deletions

View File

@@ -131,8 +131,8 @@ RDDownload::ErrorCode RDDownload::runDownload(const QString &username,
// otherwise some versions of LibCurl will throw a 'bad/illegal format'
// error.
//
strncpy(url,conv_src_url.toString(conv_src_url.protocol().lower()=="http"),
1024);
strncpy(url,conv_src_url.
toString(conv_src_url.protocol().lower().left(4)=="http"),1024);
curl_easy_setopt(curl,CURLOPT_URL,url);
curl_easy_setopt(curl,CURLOPT_WRITEDATA,f);
strncpy(userpwd,username+":"+password,256);