[PATCH v7 4/4] Cygwin: pty: Allow multiple apps to enable pseudo console simultaneously.

2021-01-27 Thread Takashi Yano via Cygwin-patches
- After commit bb428520, there has been the disadvantage: 7) Pseudo console cannot be activated if it is already activated for another process on same pty. This patch clears this disadvantage. --- winsup/cygwin/fhandler.h | 7 +- winsup/cygwin/fhandler_tty.cc | 344

[PATCH v7 3/4] Cygwin: pty: Make apps using console APIs be able to debug with gdb.

2021-01-27 Thread Takashi Yano via Cygwin-patches
- After commit bb428520, there has been the disadvantage: 2) The apps which use console API cannot be debugged with gdb. This is because pseudo console is not activated since gdb uses CreateProcess() rather than exec(). Even with this limitation, attaching gdb to native app, in

[PATCH v7 1/4] Cygwin: pty: Inherit typeahead data between two input pipes.

2021-01-27 Thread Takashi Yano via Cygwin-patches
- PTY has a problem that the key input, which is typed during windows native app is running, disappears when it returns to shell. This is beacuse pty has two input pipes, one is for cygwin apps and the other one is for native windows apps. The key input during windows native program is

[PATCH v7 0/4] Improve pseudo console support.

2021-01-27 Thread Takashi Yano via Cygwin-patches
The new implementation of pseudo console support by commit bb428520 provides the important advantages, while there also has been several disadvantages compared to the previous implementation. These patches overturn some of them. The disadvantage: 1) The cygwin program which calls console API

[PATCH] Cygwin: getdtablesize: always return OPEN_MAX_MAX

2021-01-27 Thread Ken Brown via Cygwin-patches
According to the Linux man page for getdtablesize(3), the latter is supposed to return "the maximum number of files a process can have open, one more than the largest possible value for a file descriptor." The constant OPEN_MAX_MAX is the only limit enforced by Cygwin, so we now return that.

fhandler_serial.cc: MARK and SPACE parity for serial port

2021-01-27 Thread Marek Smetana via Cygwin-patches
Hi, This patch add MARK and SPACE parity support to serial port --- winsup/cygwin/fhandler_serial.cc| 9 - winsup/cygwin/include/sys/termios.h | 1 + 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/winsup/cygwin/fhandler_serial.cc b/winsup/cygwin/fhandler_serial.cc

[PATCH v2] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Ken Brown via Cygwin-patches
Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to succeed on non-symlinks. Previously it always failed, as it does on Linux. But POSIX permits it to succeed on non-symlinks even if it fails on symlinks. The reason for following POSIX rather than Linux is to make gnulib report that fchmodat

Re: [PATCH] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Ken Brown via Cygwin-patches
On 1/27/2021 8:27 AM, Corinna Vinschen via Cygwin-patches wrote: On Jan 27 08:22, Ken Brown via Cygwin-patches wrote: On 1/27/2021 7:40 AM, Corinna Vinschen via Cygwin-patches wrote: On Jan 26 16:30, Ken Brown via Cygwin-patches wrote: Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to

Re: [PATCH] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Corinna Vinschen via Cygwin-patches
On Jan 27 08:22, Ken Brown via Cygwin-patches wrote: > On 1/27/2021 7:40 AM, Corinna Vinschen via Cygwin-patches wrote: > > On Jan 26 16:30, Ken Brown via Cygwin-patches wrote: > > > Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to succeed on > > > non-symlinks. Previously it always failed, as

Re: [PATCH] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Ken Brown via Cygwin-patches
On 1/27/2021 7:40 AM, Corinna Vinschen via Cygwin-patches wrote: On Jan 26 16:30, Ken Brown via Cygwin-patches wrote: Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to succeed on non-symlinks. Previously it always failed, as it does on Linux. But POSIX permits it to succeed on non-symlinks

Re: [PATCH] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Corinna Vinschen via Cygwin-patches
On Jan 26 16:30, Ken Brown via Cygwin-patches wrote: > Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to succeed on > non-symlinks. Previously it always failed, as it does on Linux. But > POSIX permits it to succeed on non-symlinks even if it fails on > symlinks. > > The reason for following

Re: [PATCH] Cygwin: fchmodat: add limited support for AT_SYMLINK_NOFOLLOW

2021-01-27 Thread Ken Brown via Cygwin-patches
On 1/26/2021 4:30 PM, Ken Brown via Cygwin-patches wrote: Allow fchmodat with the AT_SYMLINK_NOFOLLOW flag to succeed on non-symlinks. Previously it always failed, as it does on Linux. But POSIX permits it to succeed on non-symlinks even if it fails on symlinks. The reason for following POSIX

Re: [PATCH v2 7/8] dir.cc: Try unlink_nt first

2021-01-27 Thread Ben
On 26-01-2021 12:46, Corinna Vinschen via Cygwin-patches wrote: > > So what about /dev, /proc, etc? > The idea was to catch them with pc.isspecial() in unlink_nt.