UI: Add alternate constructor for RemoteTextThread

Allows specifying extra headers.
This commit is contained in:
jp9000 committed 2019-02-07 14:47:00 -08:00
1 parent 44834bbf04
commit 08e6dcd516
2 files changed
+18

No files matched your search

+3
View File
@@ -61,6 +61,9 @@ void RemoteTextThread::run()
contentTypeString.c_str());
}
for (std::string &h : extraHeaders)
header = curl_slist_append(header, h.c_str());
curl_easy_setopt(curl.get(), CURLOPT_URL, url.c_str());
curl_easy_setopt(curl.get(), CURLOPT_HTTPHEADER,
header);