[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #48458] after stty ixoff, term sends XOFF automatically, but not XO

From: Kalle Olavi Niemitalo
Subject: [bug #48458] after stty ixoff, term sends XOFF automatically, but not XON
Date: Sun, 10 Jul 2016 19:45:29 +0000 (UTC)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0 Iceweasel/38.8.0


                 Summary: after stty ixoff, term sends XOFF automatically, but
not XON
                 Project: The GNU Hurd
            Submitted by: kon
            Submitted on: Sun Jul 10 19:45:26 2016
                Category: Hurd Servers
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Hardware Support
                  Status: None
                 Privacy: Public
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
         Reproducibility: Every Time
              Size (loc): None
         Planned Release: None
                  Effort: 0.00
Wiki-like text discussion box: 



If the IXOFF input mode is enabled (e.g. with "stty ixoff"), and too much data
comes in from the terminal, then term/munge.c (input_character) sends an XOFF
character to the terminal, which should recognize the XOFF and stop sending
data.  If a program then reads the data from the input buffer, the term
translator should send a XON character to the terminal so that the terminal
will start sending data again.  However, the translator never sends this XON. 
(The XON and XOFF characters can be replaced with other characters, by setting
c_cc[VSTART] and c_cc[VSTOP] in struct termios.)

(Related to this, input_character sets the SENT_VSTOP flag in termflags when
it sends the XOFF character, but nothing never checks or clears that flag.)

To test this, first run "stty sane ixoff start '{' stop '}'" to enable the
generation of XON/XOFF and replace the characters with something visible. 
Then run "cat" and paste 8100 "a" characters.  (This number is QUEUE_HIWAT in
term/term.h.)  Type "1" and then "2".  The "2" does not echo; "}" is output
instead.  Press ^U, which is the KILL character and clears the input buffer. 
The term translator should now output "{" to the terminal, but does not.

(Also, it is wrong that the term translator sends this XOFF only when the
buffer is entirely full and a received character is about to be discarded.  It
should send the XOFF when there is still room in the buffer, so that the
terminal has some time to react.)


Reply to this item at:


  Message sent via/by Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]