From owner-freebsd-current@FreeBSD.ORG Sun Aug 2 14:05:55 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B607E106573E for ; Sun, 2 Aug 2009 14:05:55 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (skuns.zoral.com.ua [91.193.166.194]) by mx1.freebsd.org (Postfix) with ESMTP id 0E4858FC12 for ; Sun, 2 Aug 2009 14:05:54 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id n72E5Wei075062 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 2 Aug 2009 17:05:33 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3) with ESMTP id n72E5WYh010331; Sun, 2 Aug 2009 17:05:32 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3/Submit) id n72E5UHr010330; Sun, 2 Aug 2009 17:05:30 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 2 Aug 2009 17:05:30 +0300 From: Kostik Belousov To: Ed Schouten Message-ID: <20090802140530.GJ1884@deviant.kiev.zoral.com.ua> References: <20090802105033.GG1884@deviant.kiev.zoral.com.ua> <20090802123108.GY1292@hoeg.nl> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="pVmaXEaLnySzRbTt" Content-Disposition: inline In-Reply-To: <20090802123108.GY1292@hoeg.nl> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: FreeBSD Current Subject: Re: HEAD tty seems to drop characters X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Aug 2009 14:05:56 -0000 --pVmaXEaLnySzRbTt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Aug 02, 2009 at 02:31:08PM +0200, Ed Schouten wrote: > Hi Kostik, >=20 > * Kostik Belousov wrote: > > I run a screen(1), where I tried to copy large portion of output and > > paste it into vi. This resulted in the loss of the characters at random > > points inside the pasted text. >=20 > I already took some time to investigate the issue. I have attached a > patch that should already improve the situation: >=20 > - write() on a pseudo-terminal master also accounted the data that was > read into the kernel, but couldn't be passed to the TTY (which is > likely to happen in non-blocking mode). >=20 > - There was also a small unrelated issue; input on a TTY which has been > configured in block (bypass) mode wouldn't set the input high water > mark. >=20 > For some reason, the data loss doesn't occur when SSHing to myself > multiple times, but still causes screen(1) to drop some bytes later on. >=20 > Even though it's always very easy to blame other applications, I suspect > this may be because I reduced the input buffer size from 8 KB to 2 KB > per pseudo-terminal. Maybe screen(1) can't deal with this. To be > investigated... At least, it is an improvement for me. Patch looks good. Please consider this as an approval for the commit. --pVmaXEaLnySzRbTt Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkp1nSoACgkQC3+MBN1Mb4grTACgp/CY9nfAXFa+jege5EzEyZOq PdgAoKWkx0bQvPEpCeRCxdOA1sX0iBpd =Mssb -----END PGP SIGNATURE----- --pVmaXEaLnySzRbTt--