This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: setup hangs during postinstall

On Tue, Oct 14, 2003 at 10:27:45AM -0500, Brian Ford wrote:
>On Mon, 13 Oct 2003, Christopher Faylor wrote:
>> On Mon, Oct 13, 2003 at 12:22:12PM -0500, Brian Ford wrote:
>> >Since setup must be launched from explorer to hang, I set
>> >CYGWIN_DEBUG=cygpath in my system environment variables and rebooted.  To
>> >make sure it worked, I launched a bash under rxvt and did a "cygpath -S".
>> >Up popped the gdb cmd shell.  But, under setup, no dice.
>> Are you saying that there was no popup?  That would imply that CYGWIN_DEBUG
>> is not in the environment.  You could just hack on the code in to
>> automatically pop up a gdb when command line contains cygpath, as a temporary
>> measure, of course.
>Yes, but I'm sure it *was* in the environment.  In fact, after terminating
>my manually attached gdb session, it popped up (this is NT4, so cypath
>had to exit at gdb detach time).

So it must not really be cygpath that is hanging, then.  The stack trace that
you provided was more likely for an execed bash stub.  You could try setting
CYGWIN_DEBUG=bash to test that theory.

>> The stack trace below is from a process that is running cygpath not
>> from cygpath itself.
>Ok.  That is what it looked like to me too, but I don't know how the
>Cygwin "fork exec" stuff works yet (spawn_guts is huge), so I wasn't
>entirely sure.
>Maybe I was just too rushed, but I'm almost positive I attached to
>the only thing ps -ef said was cygpath.  Why does the spawner (bash?) say
>it's cygpath?

The name of the stub changes when it execs a process.  It goes something
like this:

1) Call exec

2) exec calls CreateProcess, sets up pinfo structure with newly created
   windows pid, maintaining the cygwin pid.

3) exec (stub) changes name in pinfo structure to that of execed program.

4) exec (stub) waits for execed program to say "I'm here".

4) exec (stub) exits.

So, for a brief time there are two processes attached to the same pinfo.
The task manager (and maybe ps -W) will tell you the "real" windows
process that is running.


Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]