This is the mail archive of the
cygwin-patches@cygwin.com
mailing list for the Cygwin project.
Re: [Patch]: mount_info::conv_to_posix_path
- From: Christopher Faylor <cgf-no-personal-reply-please at cygwin dot com>
- To: cygwin-patches at cygwin dot com
- Date: Thu, 6 May 2004 23:28:45 -0400
- Subject: Re: [Patch]: mount_info::conv_to_posix_path
- References: <3.0.5.32.20040506195101.008064e0@incoming.verizon.net>
- Reply-to: cygwin-patches at cygwin dot com
On Thu, May 06, 2004 at 07:51:01PM -0400, Pierre A. Humblet wrote:
>A missing return causes trouble when chroot is in effect.
>
>Pierre
>
>2004-05-07 Pierre Humblet <pierre.humblet@ieee.org>
>
> * path.cc (mount_info::conv_to_posix_path): Add return.
>
>Index: path.cc
>===================================================================
>RCS file: /cvs/src/src/winsup/cygwin/path.cc,v
>retrieving revision 1.309
>diff -u -p -r1.309 path.cc
>--- path.cc 6 May 2004 16:26:10 -0000 1.309
>+++ path.cc 6 May 2004 23:27:31 -0000
>@@ -1703,6 +1703,7 @@ mount_info::conv_to_posix_path (const ch
> posix_path[0] = '/';
> posix_path[1] = '\0';
> }
>+ return 0;
> }
> else
> return ENOENT;
Thanks. I took the opportunity to reorganize this code slightly and
used a goto to jump out of the function so that the same debugging
info was recorded for strace.
So, I've applied your patch with hopefully minor tweaks.
cgf