mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2026-11-04 10:42:04 +00:00
Enhancements
Fix filename option in web interface. Fix when failed to download any files, the program still treat it as succeeded. Add --artifact startup option to specify which artifact(s) should be generated. Tweak Emoji matching rules. Update local rulesets and configurations.
This commit is contained in:
22 files changed
+303
-96
No files matched your search
+4
-1
@@ -57,6 +57,7 @@ static std::string curlGet(std::string url, std::string proxy, std::string &resp
|
||||
{
|
||||
CURL *curl_handle;
|
||||
std::string data;
|
||||
int retVal = 0;
|
||||
|
||||
curl_init();
|
||||
|
||||
@@ -70,10 +71,12 @@ static std::string curlGet(std::string url, std::string proxy, std::string &resp
|
||||
curl_easy_setopt(curl_handle, CURLOPT_PROXY, proxy.data());
|
||||
|
||||
return_code = curl_easy_perform(curl_handle);
|
||||
curl_easy_getinfo(curl_handle, CURLINFO_HTTP_CODE, &retVal);
|
||||
curl_easy_cleanup(curl_handle);
|
||||
|
||||
if(return_code != CURLE_OK)
|
||||
if(return_code != CURLE_OK || retVal != 200)
|
||||
data.clear();
|
||||
data.shrink_to_fit();
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user