aboutsummaryrefslogtreecommitdiff
path: root/term/munge.c
Commit message (Collapse)AuthorAgeFilesLines
* 2002-02-10 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2002-02-101-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * term.h: Include `hurd/hurd_types.h'. (struct bottomhalf): Change the return types of the following members from void to error_t: abandon_physical_output, suspend_physical_output, notice_input_flushed, desert_dtr, set_break, clear_break, start_output, set_bits (which now takes an struct termios * as argument), mdmctl and mdmstate (which now takes an int * as argument). Add new members init and type. (bottom): Define as const. (devio_bottom, ptyio_bottom): Declare as const. (drop_output): Change return type from void to error_t. (ptyio_init): Remove prototype. * devio.c (devio_abandon_physical_output): Change return value to error_t, and return 0. (devio_suspend_physical_output): Likewise. (devio_notice_input_flushed): Likewise. (devio_desert_dtr): Likewise. (devio_set_break): Likewise. (devio_clear_break): Likewise. (devio_start_output): Likewise. (devio_set_bits): Likewise. (devio_mdmctl): Likewise. (devio_mdmstate): Likewise. (init_devio): Rename to ... (devio_init): ... this. Do not give constructor attribute. Change return type to error_t, and return an error value, rather than bailing out. Declare as static. (devio_bottom): Add type TERM_ON_MACHDEV and init function devio_init. (devio_set_bits): Accept new argument STATE and use that to work out the terminal state, rather than changing the global termstate. (devio_mdmstate): Accept new argument STATE and use that to return the bits. * ptyio.c: Do not include `hurd/hurd_types.h'. (ptyio_suspend_physical_output): Change return value to error_t, and return 0. Likewise. (ptyio_notice_input_flushed): Likewise. (ptyio_desert_dtr): Likewise. (ptyio_set_bits): Likewise. (ptyio_set_break): Likewise. (ptyio_clear_break): Likewise. (ptyio_mdmctl): Likewise. (ptyio_start_output): Likewise. (ptyio_abandon_physical_output): Likewise. (ptyio_mdmstate): Likewise, and accept new argument STATE. (ptyio_init): Declare as static and change return type to error_t. (ptyio_bottom): Add type TERM_ON_MASTERPTY and init function ptyio_init. (ptyio_set_bits): Accept new argument STATE and use that to work out the terminal state, rather than changing the global termstate. (ptyio_mdmstate): Accept new argument STATE and use that to return the bits. * munge.c (drop_output): Change return value to error_t. Only clear queue if there was no error. * users.c (S_term_get_bottom_type): Just return bottom->type. (set_state): Rework logic to take possible errors into account, and to delay changing the termstate until we know that we won't fail. (S_tioctl_tiocflush): Return errors properly, and clear queue only if notice_input_flushed succeeded. (open_hook): Save error value of set_bits. Save old termflags and restore them if if set_bits failed. Call set_bits with correct arguments. (S_tioctl_tiocmods): Set err to result of mdmctl. (S_tioctl_tiocmset): Likewise. (S_tioctl_tiocmbic): Likewise. (S_tioctl_tiocmbis): Likewise. (S_tioctl_tioccdtr): Likewise. (S_tioctl_tiocsdtr): Likewise. (S_tioctl_tioccbrk): Likewise for clear_break. (S_tioctl_tiocsbrk): Likewise for set_break. (S_tioctl_tiocstart): Likewise for start_output. Save old termflags and restore them if if start_output failed. (S_tioctl_tiocstop): Likewise for stop_output. (S_trivfs_io_write): Abort the operation if start_output fails. Do not call start_output if it just failed, or if there was no data to be written. * main.c (main): Initialize bottom handler (rather than special casing this for ptyio). * users.c (open_hook): Use memcpy instead bcopy and memset instead bzero. (S_tioctl_tiocgeta): Likewise. (set_state): Likewise. (open_hook): Likewise. * munge.c (rescan_inputq): Likewise.
* 2001-12-17 Roland McGrath <roland@frob.com>Roland McGrath2001-12-181-3/+5
| | | | | * munge.c (input_character): Fix DISCARD character handling so it doesn't process the character as plain input.
* Mon Mar 1 09:11:06 1999 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell1999-03-011-1/+1
| | | | | | * munge.c (output_width): If C is a tab, then the width is the offset from LOC, not the total final position of the tab. Reported by Kalle Olavi Niemitalo <tosi@ees2.oulu.fi).
* Sat Jan 30 00:27:14 1999 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell1999-01-301-1/+5
| | | | | * munge.c (create_queue): Make sure that malloc succeeds. Reported by OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>.
* *** empty log message ***Thomas Bushnell1996-08-121-3/+7
|
* Mon Jul 29 02:46:12 1996 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath1996-07-291-47/+48
| | | | | * munge.c (input_character): In LAST_LNEXT case, jump to `alldone' after putting the char on the queue.
* (input_character): Skip much processing if external_processing is on.Michael I. Bushnell1995-12-011-16/+22
| | | | | (output_character): Don't do tab expansion of external_processing is on. (echo_p): Never echo if external_processing is on.
* (input_character) [VSTOP]: Suspend physical output after settingMichael I. Bushnell1995-12-011-0/+1
| | | | flag.
* (reprint_line): C-r is CHAR_DC2, not DC3.Michael I. Bushnell1995-12-011-1/+1
|
* (drain_output): New function names.Michael I. Bushnell1995-11-301-3/+3
|
* (output_psize): Add variable.Michael I. Bushnell1995-09-221-9/+32
| | | | | | | | | | | (output_character): Doc fix. (write_character): New function. (echo_char): Don't update echo_qsize and echo_pstart. Use write_character and output_character, respectively, when writing HDERASE / and \. Use output_character for all the other echoing. (input_character) [VINTR || VQUIT, VSUSP]: Clear inputq and rawq and reset echo_pstart and echo_qsize. [input can't fit and ! IMAXBEL]: Likewise.
* Initial revisionMichael I. Bushnell1995-08-311-0/+725