Replace TransferItem::status with a local variable

Everywhere seems to use `getHTTPStatus` now.
This commit is contained in:
Carlo Nucera 2020-06-16 15:14:11 -04:00 committed by John Ericson
parent 289b9b8dcf
commit a835c740ca

View file

@ -56,7 +56,6 @@ struct curlFileTransfer : public FileTransfer
Callback<FileTransferResult> callback;
CURL * req = 0;
bool active = false; // whether the handle has been added to the multi object
std::string status;
unsigned int attempt = 0;
@ -175,6 +174,7 @@ struct curlFileTransfer : public FileTransfer
size_t realSize = size * nmemb;
std::string line((char *) contents, realSize);
printMsg(lvlVomit, format("got header for '%s': %s") % request.uri % trim(line));
std::string status;
if (line.compare(0, 5, "HTTP/") == 0) { // new response starts
result.etag = "";
auto ss = tokenizeString<vector<string>>(line, " ");