Unexpected / unportable --output-dir behaviour #7218
I did this
Curl attempts to write file to "/index.html" instead of "index.html"
In fact, when merging the output-dir and the actual file name curl explicitly uses
I expected the following
More consistent and platform agnostic behaviour. Perhaps it would be more portable to actually
curl 7.77.1-DEV (x86_64-pc-linux-gnu) libcurl/7.77.1-DEV OpenSSL/1.1.1k zlib/1.2.11 brotli/1.0.9 libidn2/2.3.0 libpsl/0.21.0 (+libidn2/2.3.0) libssh2/1.9.0 nghttp2/1.43.0 librtmp/2.3 OpenLDAP/2.4.57
Linux hostname 5.10.0-6-amd64 #1 SMP Debian 5.10.28-1 (2021-04-09) x86_64 GNU/Linux
The text was updated successfully, but these errors were encountered:
The issue with
Another (more modern) option would be to use
VMS seems to be affected, at least. They use quite "special" paths: https://wiki.vmssoftware.com/File_specification
AmigaOS and compatibles could also be problematic in some cases as "foo/bar" is "foo/bar" but "foo//bar" is "foo/../bar" ... this normally is no issue except when something assumes that multiple // are "ignored". This can become problematic if code makes assumptions about this. Technically this specific use case isn't affected by this, I think.