bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#13086: 24.2.50; Emacs seems to hang at w32proc.c:1126


From: Eli Zaretskii
Subject: bug#13086: 24.2.50; Emacs seems to hang at w32proc.c:1126
Date: Wed, 05 Dec 2012 23:25:54 +0200

> Date: Wed, 05 Dec 2012 19:28:20 +0000
> From: Stephen Powell <stephen_powell@optusnet.com.au>
> CC: stephen_powell@optusnet.com.au, 13086@debbugs.gnu.org
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > Can you use the 'finish' command, as described in etc/DEBUG, to find
> > out where it loops?
> 
> (gdb) thread 1
> [Switching to thread 1 (Thread 7752.0x1bb0)]
> #0  waitpid (pid=5528, status=0x0, options=1) at w32proc.c:1126
> 1126    {
> (gdb) finish
> Run till exit from #0  waitpid (pid=5528, status=0x0, options=1) at
> w32proc.c:1126
> 0x010e04ab in get_child_status (child=5528, status=0x0, options=1,
> interruptible=false)
>     at sysdep.c:290
> 290       while ((pid = waitpid (child, status, options)) < 0)
> Value returned is $1 = -1
> (gdb) finish
> Run till exit from #0  0x010e04ab in get_child_status (child=5528,
> status=0x0, options=1,
>     interruptible=false) at sysdep.c:290
> 
> Hung here.

I see.  I wonder why it returned -1 the first time, when the process
was still running or just exited.  Can you try setting breakpoints in
a way that will be able to explain that?

I also don't understand the logic of the loop in get_child_status.
Paul, can you tell why it loops if waitpid is called with WNOHANG and
returns -1?  Won't that cause a busy-wait loop that pegs the CPU?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]