delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2014/05/15/09:49:28

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; q=dns; s=
default; b=Z+UorG4//7abes7mIKxQpu4QknWzWz6fEnyMBql4s6So7gvMpToqd
R4cVwwmGZBoYXbhSiPNcwN4oHY/wA7XkPBM1Ped63qm0IqDHsWm70KXHz41kDkLU
8HbFs3QoD0A6ekmbvkbhQwuvxRxFqwMJKOkn0bMJ6HiC5jv3pYmQb0=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; s=default;
bh=2pEHz2K3akHKB20OvAfqjhT0/Jk=; b=elCIZL2vVDRlQQQ4YchAzMmTaBZf
XfnJ3f5b25HFoAeHqa4zxECkxnhtjxJv2PiQ46wAMLAew9+AimrrxKqmstLAeFLW
l8mgoJ0AMdMq1ETLa1+ERG6ZBlrnUuBgHdvE1ZySFoSXVlsODZ26sB0zjWdUvSvv
8cnr9ovBFwhiHaI=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/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
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-5.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2
X-HELO: calimero.vinschen.de
Date: Thu, 15 May 2014 15:49:05 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: screen on 64-bit mangles mintty/buffer
Message-ID: <20140515134905.GR2436@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <5370E144 DOT 4010905 AT shaddybaddah DOT name> <90t1n9l4g51dgrq060rc6ua48eog4178v8 AT 4ax DOT com> <5373AF2E DOT 5090402 AT shaddybaddah DOT name> <20140515071745 DOT GI2436 AT calimero DOT vinschen DOT de> <5374B8EA DOT 5080801 AT shaddybaddah DOT name>
MIME-Version: 1.0
In-Reply-To: <5374B8EA.5080801@shaddybaddah.name>
User-Agent: Mutt/1.5.23 (2014-03-12)

--Aq4SrlNverAHn87R
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On May 15 22:54, Shaddy Baddah wrote:
> Hi Corinna,
>=20
>=20
> On 2014-05-15 17:17+1000, Corinna Vinschen wrote:
> >
> >
> >Nice detective work, really.  The goldstar is well deservered :)
> >
> >On May 15 04:00, Shaddy Baddah wrote:
> >>I quickly worked out that the code has a bug for "%i". At some point
> >>the code was changed to push and pop the parameters being passed (0 and
> >>39 in my eg.). However, the "%i" select/case block was incrementing the
> >>arguments in a no longer used array for parameters:
> >>
> >>
> >>	    case 'i':
> >>		if (p_is_s[0] =3D=3D 0)
> >>		    param[0]++;
> >>		if (p_is_s[1] =3D=3D 0)
> >>		    param[1]++;
> >>		break;
> >
> >Unfortunately there's no newer upstream release and this bug is present
> >in the ncurses 5.9 version in Fedora 20 as well.  From what I gather fro=
m the
> >surrounding code, I *assume* something like this could fix it
> >
> >             case 'i':
> >                 y =3D npop();
> >                 x =3D npop();
> >                 if (p_is_s[0] =3D=3D 0)
> >                     y++;
> >                 if (p_is_s[1] =3D=3D 0)
> >                     x++;
> >                 npush(x);
> >                 npush(y);
> >                 break;
> >
> >I'm not sure the relation between x, y, and the p_is_s indices is
> >correct, though.
>=20
> Yes, that's the code that I thought of as well, and same, I'd have to
> get my head around the exact order of p_is_s (unfortunate name), etc.
>=20
> When you say the bug is present in ncurses 5.9, is there any application
> that is directly affected? I ask as screen being affected was sort of a
> fluke. It's configure script should have detected terminfo notation was
> available for use, and used the equivalent entry for "cs".

Well, according to Murphy, if there's a bug, it will be hit.

One of them is, for instance, tcsh, which still uses the termcap
functions deliberately for compatibility with old systems, even when
linked against [n]curses[w].  Fortunately tcsh doesn't try to use really
fancy terminal sequences...

There are very likely more projects out there doing that.  And on many
systems the only way to get the termcap functions is to use ncurses.


Corinna

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--Aq4SrlNverAHn87R
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJTdMXRAAoJEPU2Bp2uRE+gP3oP/3HSre4hqVqn6nlVBN6EYypt
f5Pi0pRDoQwJDzf1MWuFCxb1W5LUANkGDsrwW1dmajhEbfv8djTFNDJ2disxr9DS
Ca30V2guRQ9aPOEgw9qh8RAGDY1X6JBtEMDjfxQr0j1WZVWLvTzPPGYQ+ODalIAX
0E6d/gSFlFs9SfMF3jPanU8aSHLVHuXfyRjHly/c5X+k8i4HQJKYvHUj49LOTo2W
ddV++gXplZwCYWZrj4RkaoAnRA+oTLUEfz0ihZY2TWciUGVsZxzXHmsDlt16z4gs
dpshovnTpd7/o1P5pGthIZebJgZKaTfwNN/SG7C/Ph4YL99IuqL+89L6DQtdBHUw
C7ieGVaIziJ49uTvGACNwbCIzsHOj7F8f1wlDdQntZ3pA8flxSWRDE3zNEOlpjji
animfefqhVYTaQUpUeiDYy096MnB7NLkU17y9v/ECU/ENq+pJwXy65eSzvS71OPB
HAMn3H1SGpdOQK+DBJqtSguZzIT3siNfgP0vRivfA4chSfYS/BQbad6DQCFfTdVw
JVCr+IpUNcs2/hsYRO0D5MmciL2d3SVXxB3ycUVanl0UNPAkDStoDUCH6ISO2YtD
jsVSJIpK2su54lCGe2uFkwWd+vF0xd86O3Icm4zeydMaLkyq7r8BTRKh0H0UNlPt
tk/K2CFPEMapxjwuTBeU
=6Zij
-----END PGP SIGNATURE-----

--Aq4SrlNverAHn87R--

- Raw text -


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