There is a bug in libcurl 8.5.0 - 8.7.1 that causes a crash if you mix http and ftp requests in the same handle. Unfortunately these versions of libcurl are common on both Linux and MacOS.
A reprex that crashes both on Ubuntu 24.04 and all current MacOS versions:
Pooling handles is a legacy feature that is not recommended anymore. The only use is sharing cookies between requests. However FTP requests don't have cookies, so it makes no sense to pool the handle. A straightforward fix therefore is to only pool handles for http requests.
Even though httr is not intended for FTP and not actively maintained, I still think we should push this fix.
There is a bug in libcurl 8.5.0 - 8.7.1 that causes a crash if you mix http and ftp requests in the same handle. Unfortunately these versions of libcurl are common on both Linux and MacOS.
A reprex that crashes both on Ubuntu 24.04 and all current MacOS versions:
Pooling handles is a legacy feature that is not recommended anymore. The only use is sharing cookies between requests. However FTP requests don't have cookies, so it makes no sense to pool the handle. A straightforward fix therefore is to only pool handles for http requests.
Even though httr is not intended for FTP and not actively maintained, I still think we should push this fix.