curl-library
Re: Any way to make file:// urls use a relative path?
From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 19 Mar 2018 00:32:34 +0100 (CET)
Date: Mon, 19 Mar 2018 00:32:34 +0100 (CET)
On Sun, 18 Mar 2018, Tetetest wrote:
> In libcurl 7.48.0, I could read a file from current working directory by
> using "file://filename.ext" URL. After upgrading to 7.59.0, this is no
> longer possible:
Relative paths are not possible with file://. It may have been possible
before, (more or less by accident) but over recent years we've worked on
making sure curl A) acts more similar to browsers on the same input and B)
doesn't trick users into getting something they didn't expect.
You can still get something based on the current directory by inserting it
yourself into the URL, like reading README from current directory:
curl file://`pwd`/README
-- / daniel.haxx.se ------------------------------------------------------------------- Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.htmlReceived on 2018-03-19