How do I specify a path with libcurl for file uploads/downloads? or What's the correct way to specify

14 Replies, 1287 Views

Thanks everyone! This makes way more sense now. I didn’t realize libcurl specify path required the file handle upfront.

Tried your suggestions and got it working with `fopen()` + `CURLOPT_READDATA`. Still weird that the docs don’t scream "YOU NEED A FILE HANDLE" though.

Quick follow-up: What’s the best way to handle errors if `fopen()` fails? Should I just bail out, or is there a libcurl-specific way to handle it?

Also, big thanks for the Windows/Linux tips—saved me a ton of time!

Messages In This Thread



Users browsing this thread: 1 Guest(s)