public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Dan Kegel <dank@kegel.com>
To: cygwin@cygwin.com
Subject: Re: GNU screen trouble
Date: Sat, 27 May 2017 18:00:00 -0000	[thread overview]
Message-ID: <CAPF-yOa+OUBgBE_yrWYbvxLpYHKZzUtQ-qA=C_i6w62h+YDJQw@mail.gmail.com> (raw)
In-Reply-To: <16810313565.20170527142723@yandex.ru>

On Sat, May 27, 2017 at 4:27 AM, Andrey Repin <anrdaemon@yandex.ru> wrote:
> # uname -a; screen --version; screen -admS mc-server-session
> CYGWIN_NT-6.1 daemon2 2.8.0(0.309/5/3) 2017-04-01 20:47 x86_64 Cygwin
> Screen version 4.05.01 (GNU) 25-Feb-17
>
> # screen -S mc-server-session -Q windows
> <hangs infinitely>

I see something similar:

$ uname -a
CYGWIN_NT-10.0 WIN10-BB-01 2.6.0(0.304/5/3) 2016-08-31 14:32 x86_64 Cygwin

buildbot@WIN10-BB-01 ~
$ apt-cyg install screen
$ screen --version
Screen version 4.04.00 (GNU) 19-Jun-16

$ screen
(inside the new screen:)
$ screen -Q info
(hangs 3 out of 4 tries so far)

On Linux, same sequence outputs stuff to stdout without hanging.

strace on cygwin shows
...
  204  185879 [main] screen 13324 fhandler_base::close: closing
'/tmp/uscreens/S-buildbot/16948.pty1.WIN10-BB-01-queryA' handle 0x288
  114  185993 [main] screen 13324 chmod: 0 =
chmod(/tmp/uscreens/S-buildbot/16948.pty1.WIN10-BB-01-queryA, 0600)
   94  186087 [main] screen 13324 getpid: 13324 = getpid()
   40  186127 [main] screen 13324 cygwin_listen: 0 = listen(3, 5)
   34  186161 [main] screen 13324 getpid: 13324 = getpid()
   34  186195 [main] screen 13324 fcntl64: fcntl(3, 6, ...)
   36  186231 [main] screen 13324 fhandler_socket::fcntl: owner set to 13324
   33  186264 [main] screen 13324 fcntl64: 0 = fcntl(3, 6, 0x340C)
   34  186298 [main] screen 13324 seteuid32: uid: 197609 myself->uid:
197609 myself->gid: 197121
   34  186332 [main] screen 13324 seteuid32: Nothing happens
   33  186365 [main] screen 13324 setegid32: new egid: 197121 current: 197121
   40  186405 [main] screen 13324 sigaction_worker: signal 19, newact
0xFFFF8800 (handler 0x100422520), oa 0xFFFF8680
   34  186439 [main] screen 13324 sigaction: 0 = sigaction(19,
0xFFFF8800, 0xFFFF87E0)
   34  186473 [main] screen 13324 sigaction_worker: signal 1, newact
0xFFFF8800 (handler 0x100422530), oa 0xFFFF8680
   34  186507 [main] screen 13324 sigaction: 0 = sigaction(1,
0xFFFF8800, 0xFFFF87E0)
   40  186547 [main] screen 13324 write: write(4, 0xFFFF8880, 12584)
  371  186918 [main] screen 13324 write: 12584 = write(4, 0xFFFF8880, 12584)
   75  186993 [main] screen 13324 close: close(4)
  157  187150 [main] screen 13324 fhandler_socket::close: 0 =
fhandler_socket::close()
   51  187201 [main] screen 13324 close: 0 = close(4)
   36  187237 [main] screen 13324 set_signal_mask: setmask 0, newmask
0, mask_bits 0
   33  187270 [main] screen 13324 handle_sigsuspend: oldmask 0x0, newmask 0x0

The hang is after that handle_sigsuspend line in the three times I've seen it,
right before screen would have printed Remove dead screens with 'screen -wipe'.

Seems highly repeatable, at least on my old install.
A little quality time with the source and maybe gdb would probably be
illuminating.
- Dan

--
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

  reply	other threads:[~2017-05-27 15:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-27 12:01 Andrey Repin
2017-05-27 18:00 ` Dan Kegel [this message]
2017-05-30 19:33   ` Andrew Schulman
2017-06-18 18:50 ` Andrey Repin
2017-07-21 12:58 ` Andrey Repin
2017-09-27 19:05 ` Andrey Repin
2017-09-27 20:27   ` Andrey Repin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAPF-yOa+OUBgBE_yrWYbvxLpYHKZzUtQ-qA=C_i6w62h+YDJQw@mail.gmail.com' \
    --to=dank@kegel.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).