delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/01/21/10:34:12

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Wed, 21 Jan 2004 01:33:51 -0500
From: Christopher Faylor <cgf-no-personal-reply-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: some notes on debugging screen
Message-ID: <20040121063351.GA3151@redhat.com>
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20040120171119 DOT GA25428 AT redhat DOT com> <Law9-OE28sACIzKxJHW00015564 AT hotmail DOT com>
Mime-Version: 1.0
In-Reply-To: <Law9-OE28sACIzKxJHW00015564@hotmail.com>
User-Agent: Mutt/1.4.1i
X-IsSubscribed: yes
Reply-To: cygwin AT cygwin DOT com

On Tue, Jan 20, 2004 at 09:59:21AM -0800, Rafael Kitover wrote:
>FWIF, the code sending the EINVAL is around line 1105 in
>winsup/cygwin/fhandler_tty.cc:
>
>    case TIOCSWINSZ:
>      if (get_ttyp ()->winsize.ws_row != ((struct winsize *) arg)->ws_row
>          || get_ttyp ()->winsize.ws_col != ((struct winsize *) arg)->ws_col)
>        {
>          if (!ioctl_request_event)
>            get_ttyp ()->ioctl_retval = -EINVAL;
>          else
>            {
>              get_ttyp ()->arg.winsize = *(struct winsize *) arg;
>              SetEvent (ioctl_request_event);
>              get_ttyp ()->winsize = *(struct winsize *) arg;
>              killsys (-get_ttyp ()->getpgid (), SIGWINCH);
>              if (ioctl_done_event)
>                WaitForSingleObject (ioctl_done_event, INFINITE);
>            }
>        }
>      break;
>
>Commenting out the second if/else allows you to send TIOCSWINSZ
>commands to the terminal, making the screens the correct number of
>lines and columns.  After this you can see that screen works correctly.
>THIS IS NOT the problem though, just something I noticed.  Screens
>still start with the wrong size.

On reflection, the code above (which I happened to have written) didn't
look right to me, so I did a little digging.  I think I was either
confused when I wrote it or I'm confused now.  Assuming, as always, that
I'm less confused now than I was then (an assumption I probably made
when I made my change in September), I've semi-reverted this code to a
state that somewhat mirrors what it used to look like last September and
am regenning a snapshot now.  It will be interesting to see if this
solves the problem or not.

cgf

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019