ctrl-c to windows program causes mintty to hang [1.7.20 / win7]

Andrey Repin anrdaemon@freemail.ru
Sun Jun 9 13:05:00 GMT 2013

Greetings, Jeremy Hetzler!

> All,

> Steps:
> - Open mintty
> - Run a Windows program like c:\windows\system32\ping.exe
> - While the Windows program is running, press ctrl-c

> Result:
> - Windows program exits (disappears from task manager)

Check it with ping -t
It doesn't exit.

> - mintty hangs

> mintty's state in ps then appears as O ("waiting to output to a TTY").
> It does not respond to keyboard, mouse, or kill -9. It can be closed
> via task manager.

> Sending ctrl-c to Cygwin programs does not exhibit this problem. This
> behavior is new for me under 1.7.20. I have rebooted since updating
> Cygwin to no effect. Cygcheck output attached.

> Any ideas?

It's more interesting, than that.
The events are as follows:
1. Start mintty.
It starts bash and present you with a command prompt.

[]$ ps
     4212       1    4212       4212  cons0   1004 16:58:35 /usr/bin/ps
    16116       1   16116      16116  ?       1004 16:58:28 /usr/bin/mintty
I    8708   16116    8708       6208  pty0    1004 16:58:28 /usr/bin/bash

2. Execute "/c/WINDOWS/system32/ping.exe -t localhost"
It starts YET ANOTHER bash, not visible to ps, even in -W mode, but clearly
spotted in task manager.
Module:                bash.exe
Full path:             C:\Programs\CygWin\bin\bash.exe
PID:                   15688
Parent PID:            6208  (bash.exe)
Priority:              8
Threads:               2

3. Now, if you Ctrl+C, the console hangs.
If you let it sit down and think a bit, the iterrupt will be delivered to ping
and it get out of the lockup.

Going to grab a snapshot and see if it affect anything.

Standard console doesn't exhibit the lockup.

Andrey Repin (anrdaemon@freemail.ru) 09.06.2013, <16:56>

Sorry for my terrible english...

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

More information about the Cygwin mailing list