Opened 7 years ago

Closed 5 years ago

#267 closed defect (fixed)

Make _abspath() use path rewrite feature

Reported by: dmik Owned by: bird
Priority: normal Milestone: libc-0.6.6
Component: libc Version: 0.6.4
Severity: normal Keywords:
Cc:

Description

It seems that _abspath() does not involve a call to __libc_PathRewrite() to expand things like /@unixroot/my/path to proper paths. As a result, an attempt to call this function on such a path will return X:/@unixroot/my/path (where X: is the current drive) which in most cases will be a completely invalid path (which doesn't lead to what the original path before calling _abspath() would lead to).

More details are here http://svn.netlabs.org/qt4/ticket/282.

Change History (3)

comment:1 Changed 6 years ago by bird

  • Component changed from baselayout to libc
  • Milestone set to libc-0.6.6
  • Severity changed from blocker to normal
  • Status changed from new to accepted

comment:2 Changed 5 years ago by bird

The _abspath implemenation has other quirks, like _abspath("/dev/nul") or _abspath("/pipe/mypipe") will come out equally messed up by drive letters. Not to mention anything starting with a slash (or more than three) in chroot'ed mode.

Then there seems to be confusion as to what qualifies as a UNC path. The code only checks for two leading slashes before it concludes that it's a UNC path. That's not how OS/2 and Windows detects UNC paths - there should be exactly two slashes, no more.

The /dev/xxx and /pipe/yyy stuff is going to be interesting... I think we're just going to have to live with them never getting a drive letter in front of them. The path rewriting should be easier to handle, I think...

comment:3 Changed 5 years ago by bird

  • Resolution set to fixed
  • Status changed from accepted to closed

Implemented in r3924 (0.6) and r3925 (trunk).

Note: See TracTickets for help on using tickets.