News for hackers. Stuff that matters.
Re:A new Curl logo by vermilingua on Friday May 27, 2016 @08:44AM (#11785616)
In file:///, the file:// part signifies the protocol (think http://) and the / in /path/to/file signifies the root directory (think / in /home/user/)

I have never seen file:/ used before, so I can't really comment, but it seems invalid to me (and browsers auto-redirect it to ///).

Re:A new Curl logo by jameshart on Friday May 27, 2016 @08:55AM (#11785663)
Almost.

The file: signifies the protocol. The /// is actually //<machinename>/ with an empty machinename as a shorthand for 'localhost'.

Re:A new Curl logo by MoSal on Friday May 27, 2016 @09:37AM (#11785901)
Interesting.

Why is this interpreted as a relative path?

     cd /etc
     curl file://resolv.conf
Re:A new Curl logo by throwanem on Friday May 27, 2016 @10:15AM (#11786169)
Well, it's ill-formed, so what the UA does with it isn't really specified; cURL presumably treats it as a path relative to . because that's what the developer(s) decided that cURL should do. (For comparison, Firefox transforms it into file:///resolv.conf, then tries to find /resolv.conf on localhost and fails.)