From: Kacper Michajlow <kasper93@gmail.com>
To: The Cygwin Mailing List <cygwin@cygwin.com>
Subject: Re: "tmux open terminal failed: not a terminal" in terminal emulators other than mintty
Date: Sat, 16 May 2020 21:35:25 +0200 [thread overview]
Message-ID: <CABPLASTO5XDHZQbDdhu6uyS6Ci=FhA6zjObPqjcuwyk99daiFQ@mail.gmail.com> (raw)
In-Reply-To: <CAALQ5r=uz190EuTUBF6F-bybLR7zGo-FRCgV3_ff22Cj3pbjrQ@mail.gmail.com>
On Fri, 27 Mar 2020 at 21:15, Michael Wild via Cygwin <cygwin@cygwin.com>
wrote:
> Hi
>
> As the maintainer of the tmux Cygwin package I have to admit that I have no
> idea how to fix this. Sorry.
>
Hi,
I did take a look how tmux works and what is going on in Cygwin. Here is
short summary of my findings.
* Tmux sends each client stdio fd to the server through socket. Cygwin does
not support passing file descriptors over to other processes so this fails.
* Tmux has a hack for Cygwin where it opens tty by name provided by
client...
And now there are two cases:
1. When there is no pseudo terminal. cmd.exe, (WT and most other terminal
emulators out there)
* Tmux server will try to open /dev/cons<N> by name provided by client, but
this fails with ENOENT, because server process doesn't see this device.
2. When there is allocated pseudo terminal
* Tmux server will try to open /dev/pty<N> by name provided by client and
actually work.
Is there a way to make tmux work with /dev/cons<N>? I have seen in docs
/dev/cons1 Console device names are pseudo device names, only accessible
... from processes within this very console session. This is due
to a restriction in Windows.
So it likely means that whatever we do it will not be accessible from
another process.
Is this docs still holds true in latest Windows? I have seen a path to
always allocate pty for native applications, maybe this would actually
resolve this problem too.
Best Regards,
Kacper
prev parent reply other threads:[~2020-05-16 19:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-26 17:52 Kacper Michajlow
2020-03-26 19:04 ` Andrey Repin
2020-03-27 13:27 ` Kacper Michajlow
2020-03-27 20:15 ` Michael Wild
2020-05-16 19:35 ` Kacper Michajlow [this message]
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='CABPLASTO5XDHZQbDdhu6uyS6Ci=FhA6zjObPqjcuwyk99daiFQ@mail.gmail.com' \
--to=kasper93@gmail.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).