delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/12/06/14:47:18

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <3C0FCB23.2EDCC0B0@verizon.net>
Date: Thu, 06 Dec 2001 11:46:43 -0800
From: David Rothenberger <d DOT roth AT verizon DOT net>
X-Mailer: Mozilla 4.79 [en] (Windows NT 5.0; U)
X-Accept-Language: en
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: cygwin 1.3.6-3 and xemacs
References: <Pine DOT WNT DOT 4 DOT 33 DOT 0112060937500 DOT 1404-100000 AT MSD-PC3> <20011206154936 DOT GA22573 AT redhat DOT com> <20011206175147 DOT GB28243 AT localhost>

I've done a little debugging and here's what I've found out.

It appears to be a problem/change to the behavior of
cygwin_posix_to_win32_path_list().  When this function is called with a
path of the form "/cygdrive/z/something", it returns an empty string
unless the drive "z" actually exists.  This seems incorrect to me, since
this function always returns a valid Windows path for other POSIX paths,
even if the file or directory doesn't actually exist.

Even more troubling, the function appears to return garbage when called
with "/cygdrive/z" or "/cygdrive/z/", unless "z" is a valid drive.

Dave

P.S. I used the following little test program to play with this.

#include <stdio.h>

int main (int argc, char** argv)
{
    char* name = argv[1];
    char* tmp;
    printf("name = %s\n", name);
    tmp = alloca (cygwin_posix_to_win32_path_list_buf_size(name));
    cygwin_posix_to_win32_path_list(name, tmp);
    printf("%s -> %s\n", name, tmp);
    return 0;
}


"Ryan T. Sammartino" wrote:
> 
> On Thu, Dec 06, 2001 at 10:49:36AM -0500, Christopher Faylor wrote:
> > Someone should actually *debug the problem*.
> 
> This is what I'm (attempting) to do... just thought I'd alert people to
> the problem in case someone already had a fix or workaround before I
> invested the time.
> 
> I'll let you know what I come up with, if anything.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019