Re: [PATCH v2] Cygwin: respect PC_SYM_FOLLOW and PC_SYM_NOFOLLOW_REP with inner links

2021-07-07 Thread Jeremy Drake via Cygwin-patches
On Mon, 31 May 2021, Corinna Vinschen wrote:

> So we have two contradict problems, one which is solved by following
> inner symlinks, one which is solved by not doing that...

I hesitate to suggest it, but maybe an option/setting in the CYGWIN
variable as to whether to use this new behavior?  I am pretty much out of
ideas on how to make it work with native programs where they expect to see
the subst or mapped drive, not the target or UNC path.  Then MSYS2 could
either patch to change the default, or else just tell the (probably few)
people who hit it how to change the setting.


Re: [PATCH] Re: propagate font zoom via SIGWINCH

2021-07-07 Thread Corinna Vinschen
On Jul  7 11:43, Thomas Wolff wrote:
> Update with more elaborate commit comment, hopefully formatted properly.
> 
> Am 06.07.2021 um 16:09 schrieb Corinna Vinschen:
> > Hi Thomas,
> > 
> > On Jul  3 18:19, Thomas Wolff wrote:
> > > xterm 368 and mintty 3.5.1 implement a new feature to support notification
> > > of terminal scaling via font zooming also if the terminal text dimensions
> > > (rows/columns) stay unchanged, using ioctl(TIOCSWINSZ), raising SIGWINCH.
> > > This does not work in cygwin currently. The attached patch fixes that.
> > > Thomas
> > Can you please put the describing text into the commit message?
> > 
> > 
> > Thanks,
> > Corinna
> 

> Subject: [PATCH] tty/pty: support TIOCSWINSZ pixel-size-only change
>  notification
> 
> xterm 368 and mintty 3.5.1 implement a new feature to support 
> notification of terminal scaling via font zooming also if the terminal 
> text dimensions (rows/columns) stay unchanged, using 
> ioctl(TIOCSWINSZ), raising SIGWINCH;
> this patches cygwin to support that scenario
> 
> ---
>  winsup/cygwin/fhandler_tty.cc | 10 --
>  1 file changed, 8 insertions(+), 2 deletions(-)

Pushed.

Thanks,
Corinna


[PATCH] Re: propagate font zoom via SIGWINCH

2021-07-07 Thread Thomas Wolff

Update with more elaborate commit comment, hopefully formatted properly.

Am 06.07.2021 um 16:09 schrieb Corinna Vinschen:

Hi Thomas,

On Jul  3 18:19, Thomas Wolff wrote:

xterm 368 and mintty 3.5.1 implement a new feature to support notification
of terminal scaling via font zooming also if the terminal text dimensions
(rows/columns) stay unchanged, using ioctl(TIOCSWINSZ), raising SIGWINCH.
This does not work in cygwin currently. The attached patch fixes that.
Thomas

Can you please put the describing text into the commit message?


Thanks,
Corinna


From b9795ed6ec3979f68173e54d01e681271eea4a9a Mon Sep 17 00:00:00 2001
From: Thomas Wolff 
Date: Sat, 3 Jul 2021 00:00:00 +0200
Subject: [PATCH] tty/pty: support TIOCSWINSZ pixel-size-only change
 notification

xterm 368 and mintty 3.5.1 implement a new feature to support 
notification of terminal scaling via font zooming also if the terminal 
text dimensions (rows/columns) stay unchanged, using 
ioctl(TIOCSWINSZ), raising SIGWINCH;
this patches cygwin to support that scenario

---
 winsup/cygwin/fhandler_tty.cc | 10 --
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/winsup/cygwin/fhandler_tty.cc b/winsup/cygwin/fhandler_tty.cc
index 1ed41d3b2..f2ac26892 100644
--- a/winsup/cygwin/fhandler_tty.cc
+++ b/winsup/cygwin/fhandler_tty.cc
@@ -1687,7 +1687,10 @@ fhandler_pty_slave::ioctl (unsigned int cmd, void *arg)
   break;
 case TIOCSWINSZ:
   if (get_ttyp ()->winsize.ws_row != ((struct winsize *) arg)->ws_row
- || get_ttyp ()->winsize.ws_col != ((struct winsize *) arg)->ws_col)
+ || get_ttyp ()->winsize.ws_col != ((struct winsize *) arg)->ws_col
+ || get_ttyp ()->winsize.ws_ypixel != ((struct winsize *) 
arg)->ws_ypixel
+ || get_ttyp ()->winsize.ws_xpixel != ((struct winsize *) 
arg)->ws_xpixel
+)
{
  if (get_ttyp ()->pcon_activated && get_ttyp ()->pcon_pid)
resize_pseudo_console ((struct winsize *) arg);
@@ -2279,7 +2282,10 @@ fhandler_pty_master::ioctl (unsigned int cmd, void *arg)
   break;
 case TIOCSWINSZ:
   if (get_ttyp ()->winsize.ws_row != ((struct winsize *) arg)->ws_row
- || get_ttyp ()->winsize.ws_col != ((struct winsize *) arg)->ws_col)
+ || get_ttyp ()->winsize.ws_col != ((struct winsize *) arg)->ws_col
+ || get_ttyp ()->winsize.ws_ypixel != ((struct winsize *) 
arg)->ws_ypixel
+ || get_ttyp ()->winsize.ws_xpixel != ((struct winsize *) 
arg)->ws_xpixel
+)
{
  if (get_ttyp ()->pcon_activated && get_ttyp ()->pcon_pid)
resize_pseudo_console ((struct winsize *) arg);
-- 
2.32.0



Re: [PATCH v4] Cygwin: respect PC_SYM_FOLLOW and PC_SYM_NOFOLLOW_REP with inner links

2021-07-07 Thread Corinna Vinschen
On Jul  6 10:40, Jeremy Drake via Cygwin-patches wrote:
> The new GetFinalPathNameW handling for native symlinks in inner path
> components is disabled if caller doesn't want to follow symlinks, or
> doesn't want to follow reparse points.
> ---
>  winsup/cygwin/path.cc | 88 ++-
>  1 file changed, 45 insertions(+), 43 deletions(-)

Pushed.


Thanks,
Corinna