On Wed, May 4, 2022 at 12:33 PM Orgad Shaneh <org...@gmail.com> wrote: > > On Tue, May 3, 2022 at 7:10 PM Takashi Yano <takashi.y...@nifty.ne.jp> wrote: > > > > On Tue, 3 May 2022 18:52:28 +0300 > > Orgad Shaneh wrote: > > > On Tue, May 3, 2022 at 6:23 PM Takashi Yano <takashi.y...@nifty.ne.jp> > > > wrote: > > > > > > > > On Tue, 3 May 2022 14:47:17 +0300 > > > > Orgad Shaneh wrote: > > > > > Hi, > > > > > > > > > > Running `mintty ./bash` crashes on Windows 7 on cygwin-3_3-branch. > > > > > > > > > > Tested in MSYS2 on merge-3.3 branch from > > > > > https://github.com/orgads/msys2-runtime-1. It includes the tip of > > > > > cygwin-3_3-branch as of today (05827d2df8). > > > > > > > > > I cannot reproduce this with cygwin git head of cygwin-3_3-branch. > > > > Is this MSYS2 specific problem? > > > > > > You're right. I can't reproduce either. Only in my MSYS branch. > > > > > > Can you give me some guidance how to debug it? > > > > If you could identify which commit causes the issue, It would help. > > 0e1847fb87f5306cda6c022540560c5926627ae1 is the first bad commit > commit 0e1847fb87f5306cda6c022540560c5926627ae1 > Author: Takashi Yano <takashi.y...@nifty.ne.jp> > Date: Mon Feb 28 20:25:09 2022 +0900 > > Cygwin: pty: Isolate CTRL_C_EVENTs between ptys. > > - With this patch, unique invisible consoles are created for each pty > to isolate CTRL_C_EVENTs between ptys. This is necessary by Ctrl-C > handling in fhandler_termios::process_sigs() for non-cygwin apps > started in pty if the pseudo console is disabled. > > winsup/cygwin/fhandler_termios.cc | 6 ++---- > winsup/cygwin/fhandler_tty.cc | 17 +++++++++++++++++ > winsup/cygwin/tty.cc | 2 ++ > 3 files changed, 21 insertions(+), 4 deletions(-) > > I tried reverting this commit, and it fixed the crash indeed. > > - Orgad
Reduced the revert to this: @@ -979,16 +979,10 @@ fhandler_pty_slave::open (int flags, mode_t) code does not work as expected because it calls Win32 API directly rather than cygwin read()/write(). Due to this behaviour, protection based on attach_mutex does not take effect. */ get_ttyp ()->need_invisible_console = true; - else if (_major (myself->ctty) != DEV_CONS_MAJOR - && (!get_ttyp ()->invisible_console_pid - || !pinfo (get_ttyp ()->invisible_console_pid))) - /* Create a new invisible console for each pty to isolate - CTRL_C_EVENTs between ptys. */ - get_ttyp ()->need_invisible_console = true; else { acquire_attach_mutex (mutex_timeout); fhandler_console::need_invisible (); release_attach_mutex (); - Orgad -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple