diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 90b2fd863..993e74c76 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2010-12-06 Corinna Vinschen + + * path.cc (path_conv::check): Don't generate ENOENT for non-existant + CYGDRIVE and NETDRIVE paths. Add comment. + 2010-12-02 Corinna Vinschen * net.cc (get_xp_ifs): Fix counting of idx to return stable interface diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc index eb0fdbefb..ff3e3f034 100644 --- a/winsup/cygwin/path.cc +++ b/winsup/cygwin/path.cc @@ -1035,8 +1035,15 @@ out: is used on it. */ dev.parse (FH_FS); } - else if (isvirtual_dev (dev.devn) && fileattr == INVALID_FILE_ATTRIBUTES) + else if (isproc_dev (dev.devn) && fileattr == INVALID_FILE_ATTRIBUTES) { + /* FIXME: Usually we don't set error to ENOENT if a file doesn't + exist. This is typically indicated by the fileattr content. + So, why here? The downside is that cygwin_conv_path just gets + an error for these paths so it reports the error back to the + application. Unlike in all other cases of non-existant files, + for which check doesn't set error, so cygwin_conv_path just + returns the path, as intended. */ error = ENOENT; return; }