C libcurl get output into a string
You can set a callback function to receive incoming data chunks using curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, myfunc); The callback will take a user defined argument that you can set using curl_easy_setopt(curl, CURLOPT_WRITEDATA, p) Here’s a snippet of code that passes a buffer struct string {*ptr; len} to the callback function and grows that buffer on each call … Read more