1 /* 2 * Copyright (c) 1980 Regents of the University of California. 3 * All rights reserved. 4 * 5 * %sccs.include.redist.c% 6 */ 7 8 #ifndef lint 9 static char sccsid[] = "@(#)flush_in.c 5.4 (Berkeley) 06/01/90"; 10 #endif /* not lint */ 11 12 # include <curses.h> 13 14 /* 15 * flush_in: 16 * Flush all pending input. 17 */ 18 flush_in() 19 { 20 # ifdef TIOCFLUSH 21 ioctl(fileno(stdin), TIOCFLUSH, NULL); 22 # else TIOCFLUSH 23 crmode(); 24 # endif TIOCFLUSH 25 } 26