GNOME Bugzilla – Bug 135877
gtkfilesystemunix.c, canonicalize_filename
Last modified: 2008-11-18 16:22:49 UTC
I'm pretty sure that two initial slashes should be left alone, i.e., that they have a different meaning than a single slash. See, for example, http://www.ussg.iu.edu/hypermail/linux/kernel/9708.1/0369.html
I asked the MC maintainer, as MC does handle // prefixes. I don't know if this is an obsolete QNX-ism, or just for Windows system, or if it does make sense on generic Unixes.
Pavel Roskin, the MC maintainer, says this: [Federico] > Morten Welinder sent a bug report about the Unix backend not > handling a "//" prefix correctly when canonicalizing path names. MC > tends to be my canonical source for Unix file management examples, > so I resorted to it again. I found a few things: > > 1. Really old versions had an "#ifdef __QNX__" in > canonicalize_pathname(), and they preserved prefixes of the form > //[numbers]. > > 2. On 2002-02-18, the ChangeLog says you special-cased this only for > QNX, so that it wouldn't work on Neutrino. > > 3. On 2003-03-10, this got completely removed. Did QNX just drop > support for this kind of path prefixes, or was this an oversight > when rewriting the function?It was an intentional decision to drop > support for an obsolete OS. > > 4. On 2004-01-23, a similar thing got added again, but for any > //[foo] prefix (not just numbers), and a comment in the source > mentions "UNC paths". Is this just for Windows, or does it make > sense in Unix too? [Pavel] It was requested for Windows, but I guess QNX would be happy with it too. If you want to write QNX specific code, you can check that the server part consists only of numbers. But I think UNC paths are quite universal, and if the user types //server/directory we can assume that the user means a UNC path, whether the OS supports it or not. It's up to the OS to tell user if it supports only numbers there or server names as well.
Mass changing gtk+ bugs with target milestone of 2.4.2 to target 2.4.4, as Matthias said he was trying to do himself on IRC and was asking for help with. If you see this message, it means I was successful at fixing the borken-ness in bugzilla :) Sorry for the spam; just query on this message and delete all emails you get with this message, since there will probably be a lot.
Is this still an issue in gtk+ 2.12 or later, or can this be closed as OBSOLETE?
This is obsolete with the GIO backend, thanks!