From owner-freebsd-commit Wed Oct 25 23:57:55 1995 Return-Path: owner-commit Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id XAA16017 for freebsd-commit-outgoing; Wed, 25 Oct 1995 23:57:55 -0700 Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id XAA15999 for cvs-all-outgoing; Wed, 25 Oct 1995 23:57:51 -0700 Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id XAA15987 for cvs-sys-outgoing; Wed, 25 Oct 1995 23:57:45 -0700 Received: from Root.COM (implode.Root.COM [198.145.90.17]) by freefall.freebsd.org (8.6.12/8.6.6) with ESMTP id XAA15968 ; Wed, 25 Oct 1995 23:57:39 -0700 Received: from corbin.Root.COM (corbin [198.145.90.50]) by Root.COM (8.6.12/8.6.5) with ESMTP id XAA09358; Wed, 25 Oct 1995 23:57:38 -0700 Received: from localhost (localhost [127.0.0.1]) by corbin.Root.COM (8.6.12/8.6.5) with SMTP id XAA00198; Wed, 25 Oct 1995 23:57:08 -0700 Message-Id: <199510260657.XAA00198@corbin.Root.COM> To: Bruce Evans cc: CVS-commiters@freefall.freebsd.org, cvs-sys@freefall.freebsd.org Subject: Re: cvs commit: src/sys/kern tty_pty.c In-reply-to: Your message of "Thu, 26 Oct 95 05:11:25 +1000." <199510251911.FAA17483@godzilla.zeta.org.au> From: David Greenman Reply-To: davidg@Root.COM Date: Wed, 25 Oct 1995 23:57:03 -0700 Sender: owner-commit@FreeBSD.org Precedence: bulk >> Modified: sys/kern tty_pty.c >> Log: >> Fixed data loss in writes to pty masters. Data was almost always lost >> at the end of each write for writes of more than 1K. >> >> Fixed handling of residual count for early returns in writes to pty masters. >> It was only adjusted in 2 out of 6 cases. > >These changes should be in 2.1 too. Sigh. They should be checked more >carefully than the changes in tty_subr.c. I'm not sure what happens in >the PF_REMOTE case. cc can only be 0 in that case if the PF_REMOTE flag >changed. If that can happen, then cc may be too large to fit in the canq >and not everything is written. I've been testing the changes here. These seem to fix the data loss problems, but a cntrl-C still causes everything to wedge until I kill the 'od' in another window: root 179 112 196 508 ptcout S p0 11:54PM 0:01.71 od -v /dev/zero root 180 112 184 68 ttywai SE+ p0 11:54PM 0:00.54 cat /dev/ttyp8 -DG