MCPcopy Create free account
hub / github.com/alibaba/CicadaPlayer / updateSource

Method updateSource

framework/data_source/curl/CURLConnection.cpp:814–832  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

812}
813
814void CURLConnection::updateSource(const string &location)
815{
816 curl_easy_setopt(mHttp_handle, CURLOPT_URL, location.c_str());
817 mFileSize = -1;
818 uri = location;
819
820 if (reSolveList) {
821 curl_slist_free_all(reSolveList);
822 }
823
824 CURLSH *sh = nullptr;
825 reSolveList = CURLShareInstance::Instance()->getHosts(uri, &sh);
826 assert(sh != nullptr);
827 curl_easy_setopt(mHttp_handle, CURLOPT_SHARE, sh);
828
829 if (reSolveList != nullptr) {
830 curl_easy_setopt(mHttp_handle, CURLOPT_RESOLVE, reSolveList);
831 }
832}
833
834void CURLConnection::updateHeaderList(struct curl_slist *headerList)
835{

Callers 2

OpenMethod · 0.45
OpenMethod · 0.45

Calls 2

assertClass · 0.85
getHostsMethod · 0.80

Tested by

no test coverage detected