delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-0.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SARE_MSGID_LONG45,TW_CG,TW_VP,T_TO_NO_BRKTS_FREEMAIL |
X-Spam-Check-By: | sourceware.org |
MIME-Version: | 1.0 |
In-Reply-To: | <20100419063229.GA26209@ednor.casa.cgf.cx> |
References: | <m2r9d1cfe481004181509tb0853403qf8129030c0059f00 AT mail DOT gmail DOT com> <4BCBAFF0 DOT 9080701 AT gmail DOT com> <20100419063229 DOT GA26209 AT ednor DOT casa DOT cgf DOT cx> |
Date: | Mon, 19 Apr 2010 14:44:35 +0300 |
Message-ID: | <u2v9d1cfe481004190444la24cacabs4ac2ee530018b030@mail.gmail.com> |
Subject: | Re: 1.7.5: cygwin programs throw STATUS_ACCESS_VIOLATION exceptions |
From: | Yuval Emek <yuval DOT emek AT gmail DOT com> |
To: | cygwin AT cygwin DOT com |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT 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 |
On Mon, Apr 19, 2010 at 09:32, Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com> wrote: > On Mon, Apr 19, 2010 at 02:20:48AM +0100, Dave Korn wrote: >>On 18/04/2010 23:09, Yuval Emek wrote: >> >>> The context of the file xterm.exe.stackdump is: >>> Exception: STATUS_ACCESS_VIOLATION at eip=3D610202F7 >>> eax=3D00CE00F8 ebx=3D61229E44 ecx=3D7530783F edx=3D002D20F0 esi=3D00000= 000 edi=3D0022FA14 >>> ebp=3D61020A10 esp=3D0022C7E4 program=3DC:\cygwin\bin\xterm.exe, pid 46= 40, thread main >>> cs=3D001B ds=3D0023 es=3D0023 fs=3D003B gs=3D0000 ss=3D0023 >>> Stack trace: >>> Frame =A0 =A0 Function =A0Args >>> End of stack trace >> >>$ addr2line --exe cygwin-1.7.5-1/winsup/cygwin/cygwin1.dbg >>610202F7 >>/ext/build/netrel/src/cygwin-1.7.5-1/winsup/cygwin/dll_init.cc:78 >> >> =A0 =A071 =A0/* Initialize an individual DLL */ >> =A0 =A072 =A0int >> =A0 =A073 =A0dll::init () >> =A0 =A074 =A0{ >> =A0 =A075 =A0 =A0int ret =3D 1; >> =A0 =A076 >> =A0 =A077 =A0 =A0/* Why didn't we just import this variable? */ >> =A0 =A078 =A0 =A0*(p.envptr) =3D __cygwin_environ; >> =A0 =A079 >> >> =A0Ah. =A0Hmm. =A0That certainly does look like it's nothing to do with = the DEP or >>anything else; either we're missing a null pointer check here, or there's= some >>reason why that pointer's never supposed to be null at this point in the = code >>but somehow it is. > > p.envptr is supposed to be filled in by the call to _cygwin_crt0_common > in cygwin_attach_dll. =A0It is supposed to be set to the address of the > "environ" variable in the DLL. =A0It is not supposed to be NULL. =A0That > assignment should actually not even be necessary but the fact that > envptr may be NULL is a problem. =A0Of course, it could just be some > non-NULL garbage too. =A0Running in gdb and getting a stack trace would be > instructive. Can you be more specific? (I have been using cygwin for a while, but I never debugged it beforehand.) I can install gdb using setup.exe . What should I do then in order to obtain a stack trace? Thanks, Yuval > > The handling of the environ pointer has always made my head hurt. =A0In > retrospect, I wish I'd simplified it for 1.7.x. > > cgf > > -- > Problem reports: =A0 =A0 =A0 http://cygwin.com/problems.html > FAQ: =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 http://cygwin.com/faq/ > Documentation: =A0 =A0 =A0 =A0 http://cygwin.com/docs.html > Unsubscribe info: =A0 =A0 =A0http://cygwin.com/ml/#unsubscribe-simple > > -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |