如何将全局变量传递给curl_easy_setopt
int agent_num = rand() % 100000;
std::string agent_name = "https://127.0.0.1:443/agent/" + agent_num;
curl_easy_setopt(curl, CURLOPT_URL, agent_name);
Run Code Online (Sandbox Code Playgroud)
我尝试过不同的事情,他们给了我一个段错误任何帮助,谢谢!