This is the mail archive of the cygwin-patches@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: rootdir


Chris Faylor wrote:
> On Thu, Mar 16, 2000 at 05:49:17PM +0100, Corinna Vinschen wrote:
> >[...]
> >I've seen this first, when I added the debug output to the end
> >of path_conv::path_conv(). I was really surprised because I was
> >sure that all paths are absolute at this point. For testing
> >purposes simply try `ls -l foo' with foo in your cwd. The resulting
> >path of path_conv::path_conv is "foo" instead of "cwd\foo".
> 
> When I debug this function, full_path contains a fully specified path,
> as it should.  The default behavior of path_conv is to return a relative
> path but it does have the full path available to it internally.

Sorry, correction: I have tried it once more. You are right if
the cwd is on a local drive. I have added a debug_printf(full_path)
at the end of path_conv::path_conv() and I can get a relative path
in full_path if the cwd is on a remote drive that is _not_ mounted
with drive letter:

	cd //server/share
	strace ls -l some_file
=== snip ===
x y [main] ls 1008 path_conv::path_conv: full_path = some_file
=== snap ===

but:

	net use z: \\server\share
	cd /cygdrive/z
	strace ls -l some_file
=== snip ===
x y [main] ls 1013 path_conv::path_conv: full_path = z:\some_file
=== snap ===

Corinna

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]