Hey everyone!
I'm kinda stuck trying to figure out how to libcurl specify path correctly for file uploads/downloads.
Like, when I set `CURLOPT_READDATA` or `CURLOPT_WRITEDATA`, do I just pass the full path as a string? Or do I need to open the file myself first?
Tried something like:
`curl_easy_setopt(curl, CURLOPT_READDATA, "/home/user/file.txt");`
but it’s not working. Am I missing something obvious?
Also, does libcurl specify path differently on Windows vs Linux? Slashes, backslashes, etc.?
Any quick examples or tips would be awesome. Thanks in advance!
(btw, googled this but the docs are a bit vague, so hoping for some real-world advice here.)
I'm kinda stuck trying to figure out how to libcurl specify path correctly for file uploads/downloads.
Like, when I set `CURLOPT_READDATA` or `CURLOPT_WRITEDATA`, do I just pass the full path as a string? Or do I need to open the file myself first?
Tried something like:
`curl_easy_setopt(curl, CURLOPT_READDATA, "/home/user/file.txt");`
but it’s not working. Am I missing something obvious?
Also, does libcurl specify path differently on Windows vs Linux? Slashes, backslashes, etc.?
Any quick examples or tips would be awesome. Thanks in advance!
(btw, googled this but the docs are a bit vague, so hoping for some real-world advice here.)
