Skip to content

Commit

Permalink
UI: Handle HTTP errors for fetching remote files
Browse files Browse the repository at this point in the history
  • Loading branch information
WizardCM authored and tommyvct committed Jul 3, 2021
1 parent debc96f commit d557008
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions UI/remote-text.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ bool GetRemoteFile(const char *url, std::string &str, std::string &error,
curl_easy_setopt(curl.get(), CURLOPT_ACCEPT_ENCODING, "");
curl_easy_setopt(curl.get(), CURLOPT_HTTPHEADER, header);
curl_easy_setopt(curl.get(), CURLOPT_ERRORBUFFER, error_in);
curl_easy_setopt(curl.get(), CURLOPT_FAILONERROR, 1L);
curl_easy_setopt(curl.get(), CURLOPT_WRITEFUNCTION,
string_write);
curl_easy_setopt(curl.get(), CURLOPT_WRITEDATA, &str);
Expand Down

0 comments on commit d557008

Please sign in to comment.