delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
DomainKey-Signature: | a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:from:to:cc:subject:message-id:reply-to | |
:references:mime-version:content-type:in-reply-to; q=dns; s= | |
default; b=WXKyEfzjEOtWss/zrelWgBLBVVLePVjo2Gstm07LBPZJXVBnwum3z | |
oNP2zA6tP+mLI0f8RDFqwC/Daa/IkPu+mfZcne59LE0Q4GUgYZuyq8jlBbk/CAUN | |
tIydQMoPlZrewG798WFz3R/VUtIT+/a/lupND9sq4IvRQK2BNIdLTM= | |
DKIM-Signature: | v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:date:from:to:cc:subject:message-id:reply-to | |
:references:mime-version:content-type:in-reply-to; s=default; | |
bh=jrV8QPcDt/zXeuaMEl9KlAy0Gao=; b=OfZVZxQ13JdDwBOW2WatEdMW5m7F | |
vo48MW9P4v+Zcqex7aGh0Ipz+0LLydxPfwuG5PDOy/jQOcpJA1jEgqQLjYfdqRkX | |
MzcHtxrJZsyVIijFKNJZJ6UQMywNpzBH7FZo7Yj2mr1V2ZJWplQfDsoONGmm9SoR | |
N95Fg6rgIxPhRjA= | |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
X-Spam-SWARE-Status: | No, score=-4.4 required=5.0 tests=AWL,BAYES_00,KHOP_PGP_SIGNED autolearn=ham version=3.3.2 |
Date: | Fri, 16 Aug 2013 15:47:45 +0200 |
From: | Corinna Vinschen <corinna-cygwin AT cygwin DOT com> |
To: | cygwin AT cygwin DOT com |
Cc: | Eric Blake <eblake AT redhat DOT com> |
Subject: | Re: shell-init: error retrieving current directory |
Message-ID: | <20130816134745.GJ2562@calimero.vinschen.de> |
Reply-To: | cygwin AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com, Eric Blake <eblake AT redhat DOT com> |
References: | <CAHWeT-b80VyH382nXA2RrNmgK1jGOrFpw_t_zpJWEv7znR7pmA AT mail DOT gmail DOT com> |
MIME-Version: | 1.0 |
In-Reply-To: | <CAHWeT-b80VyH382nXA2RrNmgK1jGOrFpw_t_zpJWEv7znR7pmA@mail.gmail.com> |
User-Agent: | Mutt/1.5.21 (2010-09-15) |
X-Virus-Found: | No |
--cW+P/jduATWpL925 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Aug 16 12:00, Andy Koppe wrote: > This might be the same issue as a couple of previous unresolved > reports with the same error message, but I'm not sure, so here's a new > thread. >=20 > Steps to reproduce: > - On Windows 7, install 64-bit Cygwin into C:\cygwin, and let it > create a desktop shortcut. > - Edit /etc/fstab to change the cygdrive prefix to /. > - Double click 'Cygwin64 Terminal' desktop shortcut. >=20 > Result: a bunch of errors before the bash prompt. >=20 > shell-init: error retrieving current directory: getcwd: cannot access > parent directories: Bad file descriptor > job-working-directory: error retrieving current directory: getcwd: > cannot access parent directories: No such file or directory > job-working-directory: error retrieving current directory: getcwd: > cannot access parent directories: No such file or directory > job-working-directory: error retrieving current directory: getcwd: > cannot access parent directories: No such file or directory > chdir: error retrieving current directory: getcwd: cannot access > parent directories: No error >=20 > The errors remain if the shortcut target is changed from invoking > mintty to invoking bash directly: 'C:\cygwin\bin\bash.exe -l'. >=20 > The errors go away if 'C:\cygwin\bin' is put into the shortcut's > otherwise empty 'Start In' field. (But they stay if 'C:\' is put there > instead.) >=20 > They also go away if the cygdrive prefix is changed to anything but > the root directory. >=20 > I couldn't reproduce the issue with a 32-bit install. I tried to find the cause for this issue, but as far as I can tell, it's not a problem in Cygwin. For some reason bash seems to implement its own getcwd function, which plays a lot with calling stat on ., .., ../.., etc. All results from stat seem to make sense. The error code itself (Bad file descriptor, etc) doesn't matter. It's just some arbitrary value errno is set to at the time bash decides it doesn't like what the system calls return. By tweaking the internal function which implements the core of the system getcwd function, I could return any error value at will. Eric, can you please have a look into this issue? Something's weird with bash's getcwd implementation which is apparently only triggered in the 64 bit version. Thanks, Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --cW+P/jduATWpL925 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) iQIcBAEBAgAGBQJSDi2BAAoJEPU2Bp2uRE+g++cP/RO4zGvXyanqyd6bP59d+2LB DAi/1iujeB/cqOmPKXsky+VxgBveqstgeZGLB6NDv9jwJYlmph5boIuRyIaJfnMN jcxacGPawOj7d3FDDT/SN1R0do2PW0zl+H/jQFE+J6HxQeIkQzdiEs7Os5L9+nr0 JVEZgtuMuW6Jtua+J8ZOME32tSFWNasLlhBuMGMDnRKeFRVx7vv6kCtes5I9LkJf tQLUkgfXUEoiTBexYcnoPmAsC5xicK+dk28syySBk7eLmIpj1iT2gcmITEIv72Nk WxCirY5C0qF0T6dLEhCxCQ+sZSNhXjhLOl7U4CMSB4xggEXGJ/qLEInQ0TMSZbX6 vp6nHc5FEwZBL2XCOXnfZVUbz7I+TCvTDj6RwtNpnJP/4Lx0C1/Zc/CgiNjsItsB RRbYDqL2+FboGEEvFAXeYs2PqpWGdZokUyJywlRHz42lhS1VckV38F/e0TCi3tYc EHgk7DzlSUKTuWY/4Kfx3+JrwtJrD8GALU9uwuvKOsuqKFfCSr+Al1FVldWoxelY 1/SO7hZREFEB5nv33YzWo8WvLcETmsMWHlbHSTsM6WEaUFmqslT2FRzJnPHIQxTR Y6Mgh+Smp3jaFAiHHrpo1CNc6vzaCgBWfXYhdIUHedNySSq4EMaj5Daid9nQ/IEg OofmH/EeA3p+dRIRWmbI =fXW2 -----END PGP SIGNATURE----- --cW+P/jduATWpL925--
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |