Subject: Can curl read/write directly from a file descriptor? Need help!
Hey folks,
I’ve been messing around with curl using file descriptor instead of temp files, but I’m kinda stuck.
Like, I know you can pipe stuff in/out, but is there a *direct* way to make curl using file descriptor work? I’m trying to avoid the whole "write to disk, read back" dance for performance reasons.
Found some docs mentioning `-T -` for uploads and `-o -` for outputs, but what if I wanna use an actual fd number?
Also, why would someone prefer curl using file descriptor over regular files? Just speed, or are there other perks?
Any tips or gotchas? My scripts are getting messy with temp files, and I’d love to clean ‘em up.
Thanks in advance!
—
*PS: Sorry if this is a noob question, still getting the hang of advanced curl tricks.*
Hey folks,
I’ve been messing around with curl using file descriptor instead of temp files, but I’m kinda stuck.
Like, I know you can pipe stuff in/out, but is there a *direct* way to make curl using file descriptor work? I’m trying to avoid the whole "write to disk, read back" dance for performance reasons.
Found some docs mentioning `-T -` for uploads and `-o -` for outputs, but what if I wanna use an actual fd number?
Also, why would someone prefer curl using file descriptor over regular files? Just speed, or are there other perks?
Any tips or gotchas? My scripts are getting messy with temp files, and I’d love to clean ‘em up.
Thanks in advance!
—
*PS: Sorry if this is a noob question, still getting the hang of advanced curl tricks.*
