Module Name: src Committed By: kamil Date: Tue Nov 10 08:49:09 UTC 2020
Modified Files: src/distrib/sets/lists/base: mi src/distrib/sets/lists/debug: mi src/distrib/sets/lists/games: mi src/games: Makefile src/games/warp: Makefile config.h intrp.c score.c sig.c sig.h sm.c term.c term.h util.c util.h version.c warp.c warp.h warp.news Log Message: Integrate Warp Kit into the NetBSD build Fix the build and make it install and run with minimal required changes. To generate a diff of this commit: cvs rdiff -u -r1.1268 -r1.1269 src/distrib/sets/lists/base/mi cvs rdiff -u -r1.342 -r1.343 src/distrib/sets/lists/debug/mi cvs rdiff -u -r1.57 -r1.58 src/distrib/sets/lists/games/mi cvs rdiff -u -r1.29 -r1.30 src/games/Makefile cvs rdiff -u -r1.1 -r1.2 src/games/warp/Makefile src/games/warp/config.h \ src/games/warp/warp.news cvs rdiff -u -r1.2 -r1.3 src/games/warp/intrp.c src/games/warp/score.c \ src/games/warp/sig.c src/games/warp/sig.h src/games/warp/sm.c \ src/games/warp/term.c src/games/warp/term.h src/games/warp/util.c \ src/games/warp/util.h src/games/warp/version.c src/games/warp/warp.c \ src/games/warp/warp.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/distrib/sets/lists/base/mi diff -u src/distrib/sets/lists/base/mi:1.1268 src/distrib/sets/lists/base/mi:1.1269 --- src/distrib/sets/lists/base/mi:1.1268 Mon Nov 9 01:05:51 2020 +++ src/distrib/sets/lists/base/mi Tue Nov 10 08:49:08 2020 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1268 2020/11/09 01:05:51 kamil Exp $ +# $NetBSD: mi,v 1.1269 2020/11/10 08:49:08 kamil Exp $ # # Note: Don't delete entries from here - mark them as "obsolete" instead, # unless otherwise stated below. @@ -2366,6 +2366,7 @@ ./usr/share/games/fortune base-games-share ./usr/share/games/larn base-games-share ./usr/share/games/quiz.db base-games-share +./usr/share/games/warp base-games-share ./usr/share/gdb base-util-share ./usr/share/gdb/syscalls base-util-share ./usr/share/gnats base-gnats-share Index: src/distrib/sets/lists/debug/mi diff -u src/distrib/sets/lists/debug/mi:1.342 src/distrib/sets/lists/debug/mi:1.343 --- src/distrib/sets/lists/debug/mi:1.342 Sun Oct 18 10:10:18 2020 +++ src/distrib/sets/lists/debug/mi Tue Nov 10 08:49:09 2020 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.342 2020/10/18 10:10:18 rin Exp $ +# $NetBSD: mi,v 1.343 2020/11/10 08:49:09 kamil Exp $ ./etc/mtree/set.debug comp-sys-root ./usr/lib comp-sys-usr compatdir ./usr/lib/i18n/libBIG5_g.a comp-c-debuglib debuglib,compatfile @@ -939,6 +939,7 @@ ./usr/libdata/debug/usr/games/tetris.debug comp-games-debug debug ./usr/libdata/debug/usr/games/trek.debug comp-games-debug debug ./usr/libdata/debug/usr/games/unstr.debug comp-utils-debug debug +./usr/libdata/debug/usr/games/warp.debug comp-games-debug debug ./usr/libdata/debug/usr/games/worm.debug comp-games-debug debug ./usr/libdata/debug/usr/games/worms.debug comp-games-debug debug ./usr/libdata/debug/usr/games/wump.debug comp-games-debug debug Index: src/distrib/sets/lists/games/mi diff -u src/distrib/sets/lists/games/mi:1.57 src/distrib/sets/lists/games/mi:1.58 --- src/distrib/sets/lists/games/mi:1.57 Mon Nov 9 01:05:51 2020 +++ src/distrib/sets/lists/games/mi Tue Nov 10 08:49:09 2020 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.57 2020/11/09 01:05:51 kamil Exp $ +# $NetBSD: mi,v 1.58 2020/11/10 08:49:09 kamil Exp $ # # Note: don't delete entries from here - mark them as "obsolete" instead. # @@ -89,6 +89,7 @@ ./usr/games/trek games-games-bin ./usr/games/unstr games-utils-bin ./usr/games/wargames games-games-bin +./usr/games/warp games-games-bin ./usr/games/worm games-games-bin ./usr/games/worms games-games-bin ./usr/games/wtf games-utils-bin @@ -254,6 +255,17 @@ ./usr/share/man/cat8/dm.0 games-obsolete obsolete ./usr/share/man/cat8/strfile.0 games-obsolete obsolete ./usr/share/man/cat8/unstr.0 games-obsolete obsolete +./usr/share/games/warp/README games-games-share share +./usr/share/games/warp/smap.0 games-games-share share +./usr/share/games/warp/smap.1 games-games-share share +./usr/share/games/warp/smap.2 games-games-share share +./usr/share/games/warp/smap.3 games-games-share share +./usr/share/games/warp/smap.4 games-games-share share +./usr/share/games/warp/smap.5 games-games-share share +./usr/share/games/warp/smap.6 games-games-share share +./usr/share/games/warp/smap.7 games-games-share share +./usr/share/games/warp/warp.doc games-games-share share +./usr/share/games/warp/warp.news games-games-share share ./usr/share/man/html5/dm.conf.html games-games-htmlman html ./usr/share/man/html6/adventure.html games-games-htmlman html ./usr/share/man/html6/arithmetic.html games-games-htmlman html @@ -302,6 +314,7 @@ ./usr/share/man/html6/tetris.html games-games-htmlman html ./usr/share/man/html6/trek.html games-games-htmlman html ./usr/share/man/html6/wargames.html games-games-htmlman html +./usr/share/man/html6/warp.html games-games-htmlman html ./usr/share/man/html6/worm.html games-games-htmlman html ./usr/share/man/html6/worms.html games-games-htmlman html ./usr/share/man/html6/wtf.html games-utils-htmlman html @@ -358,6 +371,7 @@ ./usr/share/man/man6/tetris.6 games-games-man .man ./usr/share/man/man6/trek.6 games-games-man .man ./usr/share/man/man6/wargames.6 games-games-man .man +./usr/share/man/man6/warp.6 games-games-man .man ./usr/share/man/man6/worm.6 games-games-man .man ./usr/share/man/man6/worms.6 games-games-man .man ./usr/share/man/man6/wtf.6 games-utils-man .man Index: src/games/Makefile diff -u src/games/Makefile:1.29 src/games/Makefile:1.30 --- src/games/Makefile:1.29 Tue Nov 12 17:46:20 2013 +++ src/games/Makefile Tue Nov 10 08:49:08 2020 @@ -1,7 +1,7 @@ -# $NetBSD: Makefile,v 1.29 2013/11/12 17:46:20 mbalmer Exp $ +# $NetBSD: Makefile,v 1.30 2020/11/10 08:49:08 kamil Exp $ # @(#)Makefile 8.3 (Berkeley) 7/24/94 -# Missing: dungeon warp +# Missing: dungeon # Moved: chess # Don't belong: xneko xroach @@ -14,7 +14,7 @@ SUBDIR= adventure arithmetic atc \ hack hals_end hangman hunt larn mille monop morse number \ phantasia pig pom ppt primes quiz \ rain random robots rogue sail snake tetris trek \ - wargames worm worms wtf wump + wargames warp worm worms wtf wump .if ${MKCXX} != "no" SUBDIR+= dab Index: src/games/warp/Makefile diff -u src/games/warp/Makefile:1.1 src/games/warp/Makefile:1.2 --- src/games/warp/Makefile:1.1 Mon Nov 9 23:37:05 2020 +++ src/games/warp/Makefile Tue Nov 10 08:49:08 2020 @@ -1,61 +1,79 @@ -CFLAGS+=-O +# $NetBSD: Makefile,v 1.2 2020/11/10 08:49:08 kamil Exp $ + +.include <bsd.own.mk> + +PROG= warp + SRCS= bang.c init.c intrp.c move.c object.c play.c score.c sig.c term.c \ them.c us.c util.c version.c warp.c weapon.c -OBJS= bang.o init.o intrp.o move.o object.o play.o score.o sig.o term.o \ - them.o us.o util.o version.o warp.o weapon.o -warp: ${OBJS} - ${CC} ${OBJS} -o $@ -ltermlib -lm +DPADD= ${LIBTERMLIB} ${LIBM} ${LIBCOMPAT} +LDADD= -ltermlib -lm -lcompat + +CPPFLAGS+=-DHAVETERMLIB -install: warp - export PATH || exit 1 - - mv $(bin)/warp $(bin)/warp.old - - if test `pwd` != $(bin); then cp $(public) $(bin); fi - - cd $(bin); chmod 755 $(public); chown '$(CHOWNER)' $(public) - - chmod 4711 $(bin)/warp - - chmod 755 makedir - - ./makedir `./filexp $(privlib)` - - \ -if test `pwd` != `./filexp $(privlib)`; then \ -cp $(private) `./filexp $(privlib)`; \ -fi - - \ -cd `./filexp $(privlib)`; \ -chmod 755 $(private); \ -chown '$(CHOWNER)' . $(private); \ -cp /dev/null save.blurfl - - \ -if test ! -f `./filexp $(privlib)/warp.news`; then \ -cp warp.news `./filexp $(privlib)`; \ -fi - - \ -if test `pwd` != $(mansrc); then \ -for page in $(manpages); do \ -cp $$page $(mansrc)/`basename $$page .man`.$(manext); \ -done; \ -fi +CLEANFILES+=sm sm.lo smap.0 smap.1 smap.2 smap.3 smap.4 smap.5 smap.6 smap.7 +CLEANFILES+=warp.6 +HIDEGAME=hidegame +SETGIDGAME=yes +MAN= warp.6 -clean: - rm -f warp core ${OBJS} +warp.6: + ${_MKTARGET_CREATE} + cat ${.CURDIR}/warp.man > ${.TARGET} + +DPSRCS+=smap.0 smap.1 smap.2 smap.3 smap.4 smap.5 smap.6 smap.7 smap.0: smp.0 sm - sm <smp.0 >smap.0 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.0 > ${.TARGET} + smap.1: smp.1 sm - sm <smp.1 >smap.1 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.1 > ${.TARGET} + smap.2: smp.2 sm - sm <smp.2 >smap.2 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.2 > ${.TARGET} + smap.3: smp.3 sm - sm <smp.3 >smap.3 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.3 > ${.TARGET} + smap.4: smp.4 sm - sm <smp.4 >smap.4 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.4 > ${.TARGET} + smap.5: smp.5 sm - sm <smp.5 >smap.5 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.5 > ${.TARGET} + smap.6: smp.6 sm - sm <smp.6 >smap.6 + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.6 > ${.TARGET} + smap.7: smp.7 sm - sm <smp.7 >smap.7 -sm: sm.c - ${CC} sm.c -o $@ + ${_MKTARGET_CREATE} + ./sm < ${.CURDIR}/smp.7 > ${.TARGET} + +sm: sm.lo + ${_MKTARGET_LINK} + ${HOST_LINK.c} -o ${.TARGET} ${.ALLSRC} + +.if ${MKSHARE} != "no" +FILES=smap.0 smap.1 smap.2 smap.3 smap.4 smap.5 smap.6 smap.7 +FILES+=warp.doc warp.news README +FILESDIR=/usr/share/games/warp +.endif + +CFLAGS+= -Wno-error=old-style-definition -Wno-error=strict-prototypes +CFLAGS+= -Wno-error=comment -Wno-error=maybe-uninitialized +CFLAGS+= -Wno-error=discarded-qualifiers -Wno-error=dangling-else +CFLAGS+= -Wno-error=char-subscripts -Wno-error=parentheses +CFLAGS+= -Wno-error=unused-value -Wno-error=format-extra-args +CFLAGS+= -Wno-error=format-overflow= -Wno-error=builtin-declaration-mismatch +CFLAGS+= -Wno-error=format= -Wno-error=sign-compare -Wno-error=return-type +CFLAGS+= -Wno-error=unused-label -Wno-error=unused-variable +CFLAGS+= -Wno-error=format-nonliteral -Wno-error=implicit-fallthrough= -depend: ${SRCS} - mkdep ${SRCS} +.include <bsd.prog.mk> Index: src/games/warp/config.h diff -u src/games/warp/config.h:1.1 src/games/warp/config.h:1.2 --- src/games/warp/config.h:1.1 Mon Nov 9 23:37:05 2020 +++ src/games/warp/config.h Tue Nov 10 08:49:08 2020 @@ -145,5 +145,4 @@ #endif /* warp private library, may use ~ expansion, %x and %l */ -#define PRIVLIB "/usr/games/lib/warp" /**/ - +#define PRIVLIB "/usr/share/games/warp" /**/ Index: src/games/warp/warp.news diff -u src/games/warp/warp.news:1.1 src/games/warp/warp.news:1.2 --- src/games/warp/warp.news:1.1 Mon Nov 9 23:37:05 2020 +++ src/games/warp/warp.news Tue Nov 10 08:49:08 2020 @@ -1,4 +1,3 @@ *** WARP NEWS *** -Welcome to warp! Please send any gripes, comments, fantastic ideas, etc. -to lw...@sdcrdcf.uucp (Larry Wall). +Welcome to warp! Index: src/games/warp/intrp.c diff -u src/games/warp/intrp.c:1.2 src/games/warp/intrp.c:1.3 --- src/games/warp/intrp.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/intrp.c Tue Nov 10 08:49:08 2020 @@ -257,6 +257,21 @@ getout: } #endif +static char *mygets(char *str, size_t n) +{ + char *ret; + size_t last; + + if ((ret = fgets(str, n, stdin)) != NULL) { + last = strlen(str) - 1; + + if (str[last] == '\n') + str[last] = '\0'; + } + + return ret; +} + /* interpret interpolations */ char * @@ -367,7 +382,7 @@ char *stoppers; pattern = dointerp(scrbuf,(sizeof scrbuf),pattern+1,"\""); fputs(scrbuf,stdout); resetty(); - gets(scrbuf); + mygets(scrbuf, sizeof(scrbuf)); crmode(); raw(); noecho(); Index: src/games/warp/score.c diff -u src/games/warp/score.c:1.2 src/games/warp/score.c:1.3 --- src/games/warp/score.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/score.c Tue Nov 10 08:49:08 2020 @@ -35,6 +35,7 @@ score_init() Reg2 int i; FILE *savfil; +#if 0 if (stat(SAVEDIR,&filestat)) { printf("Cannot access %s\r\n",SAVEDIR); finalize(1); @@ -47,6 +48,7 @@ score_init() printf("%s is not protected correctly (must be u+rw o+rx).\r\n",SAVEDIR); finalize(1); } +#endif #ifdef SCOREFULL interp(longlognam, sizeof longlognam, "%N"); @@ -535,12 +537,12 @@ score() Reg1 FILE *logfd; Reg2 FILE *outfd; Reg3 int i; - long nowtime, time(); + time_t nowtime; char *scoreboard; for (i=0; link(LOGFILE, LOCKFILE) == -1 && i<10; i++) sleep(1); - nowtime = time((long *)0); + nowtime = time(NULL); strcpy(cdate,ctime(&nowtime)); if ((logfd = fopen(LOGFILE,"a")) != NULL) { fprintf(logfd, Index: src/games/warp/sig.c diff -u src/games/warp/sig.c:1.2 src/games/warp/sig.c:1.3 --- src/games/warp/sig.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/sig.c Tue Nov 10 08:49:08 2020 @@ -58,7 +58,7 @@ sig_init() #ifdef SIGTSTP void -cont_catcher() +cont_catcher(int x) { #ifndef lint sigset(SIGCONT,cont_catcher); @@ -110,7 +110,7 @@ int status; /* come here on signal other than interrupt, stop, or cont */ void -sig_catcher(signo) +sig_catcher(int signo) { #ifdef VERBOSE static char *signame[] = { @@ -204,7 +204,7 @@ sig_catcher(signo) /* come here on stop signal */ void -stop_catcher() +stop_catcher(int sig) { if (!waiting) { resetty(); /* this is the point of all this */ Index: src/games/warp/sig.h diff -u src/games/warp/sig.h:1.2 src/games/warp/sig.h:1.3 --- src/games/warp/sig.h:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/sig.h Tue Nov 10 08:49:08 2020 @@ -6,10 +6,10 @@ * */ -void sig_catcher(); +void sig_catcher(int); #ifdef SIGTSTP -void cont_catcher(); -void stop_catcher(); +void cont_catcher(int); +void stop_catcher(int); #endif void mytstp(); void sig_init(); Index: src/games/warp/sm.c diff -u src/games/warp/sm.c:1.2 src/games/warp/sm.c:1.3 --- src/games/warp/sm.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/sm.c Tue Nov 10 08:49:08 2020 @@ -8,8 +8,10 @@ #include <stdio.h> #include <ctype.h> +#include <stdlib.h> #include "config.h" +int main() { char screen[23][90], buf[10]; Index: src/games/warp/term.c diff -u src/games/warp/term.c:1.2 src/games/warp/term.c:1.3 --- src/games/warp/term.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/term.c Tue Nov 10 08:49:08 2020 @@ -556,9 +556,9 @@ rewrite() display_status(); } -char +int cmstore(ch) -Reg1 char ch; +Reg1 int ch; { *maxcmstring++ = ch; } Index: src/games/warp/term.h diff -u src/games/warp/term.h:1.2 src/games/warp/term.h:1.3 --- src/games/warp/term.h:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/term.h Tue Nov 10 08:49:08 2020 @@ -12,6 +12,16 @@ * */ +#ifndef TERM_H +#define TERM_H + +#include "util.h" + +/* Compat with old termios. */ +#ifndef ECHO +#define ECHO 8 +#endif + /* warp will still work without the following, but may get ahead at low speed */ #ifdef TIOCOUTQ /* chars left in output queue */ #define output_pending() (ioctl(1, TIOCOUTQ, &iocount),iocount) @@ -110,7 +120,7 @@ EXT char INTRCH INIT('\03'); # endif /* lint */ # else /* RDCHK */ # ifndef O_NDELAY /* assert O_NDELAY */ - ??? PENDING isn't defined correctly in warp.h + ??? PENDING is not defined correctly in warp.h # endif EXT int devtty INIT(0); # ifndef lint @@ -121,7 +131,7 @@ EXT char INTRCH INIT('\03'); # endif /* RDCHK */ # endif /* FIONREAD */ # else /* PENDING */ - ??? warp won't work without PENDING + ??? warp will not work without PENDING # ifndef lint # define input_pending() (nextin!=nextout) # else @@ -149,7 +159,7 @@ EXT char INTRCH INIT('\03'); # endif /* lint */ # else /* RDCHK */ # ifndef O_NDELAY /* assert O_NDELAY */ - ??? PENDING isn't defined correctly in warp.h + ??? PENDING is not defined correctly in warp.h # endif EXT int devtty INIT(0); EXT bool is_input INIT(FALSE); @@ -163,7 +173,7 @@ EXT char INTRCH INIT('\03'); # endif /* RDCHK */ # endif /* FIONREAD */ # else /* PENDING */ - ??? warp won't work without PENDING + ??? warp will not work without PENDING # define read_tty(addr,size) read(0,addr,size) # define input_pending() (FALSE) # endif /* PENDING */ @@ -278,7 +288,6 @@ EXT char KILLCH; /* line delete charact #define standout() do_tc(SO,1) #define un_standout() do_tc(SE,1) #define up_line() do_tc(UP,1) -#define carriage_return() do_tc(CR,1) #define dingaling() do_tc(VB,1) #else ???????? /* up to you */ @@ -305,4 +314,6 @@ void do_tc(); int comp_tc(); void helper(); void rewrite(); -char cmstore(); +int cmstore(int); + +#endif Index: src/games/warp/util.c diff -u src/games/warp/util.c:1.2 src/games/warp/util.c:1.3 --- src/games/warp/util.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/util.c Tue Nov 10 08:49:08 2020 @@ -97,7 +97,6 @@ safemalloc(size) MEM_SIZE size; { char *ptr; - char *malloc(); ptr = malloc(size?size:1); /* malloc(0) is NASTY on our system */ if (ptr != Nullch) Index: src/games/warp/util.h diff -u src/games/warp/util.h:1.2 src/games/warp/util.h:1.3 --- src/games/warp/util.h:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/util.h Tue Nov 10 08:49:08 2020 @@ -54,7 +54,7 @@ void movc3(); void no_can_do(); int exdis(); -EXT bool waiting INIT(FALSE); /* are we waiting for subprocess (in doshell)? */ +#define waiting 0 #ifdef NOTDEF EXT int len_last_line_got INIT(0); Index: src/games/warp/version.c diff -u src/games/warp/version.c:1.2 src/games/warp/version.c:1.3 --- src/games/warp/version.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/version.c Tue Nov 10 08:49:08 2020 @@ -10,6 +10,8 @@ #include "INTERN.h" #include "version.h" +#include <stdio.h> + /* Print out the version number. */ void Index: src/games/warp/warp.c diff -u src/games/warp/warp.c:1.2 src/games/warp/warp.c:1.3 --- src/games/warp/warp.c:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/warp.c Tue Nov 10 08:49:08 2020 @@ -132,6 +132,7 @@ char rcsid[] = "@(#)Header: warp.c,v 7.0 #include "version.h" #include "weapon.h" +int main(argc,argv) int argc; char *argv[]; Index: src/games/warp/warp.h diff -u src/games/warp/warp.h:1.2 src/games/warp/warp.h:1.3 --- src/games/warp/warp.h:1.2 Tue Nov 10 00:02:11 2020 +++ src/games/warp/warp.h Tue Nov 10 08:49:08 2020 @@ -12,16 +12,23 @@ * */ +#ifndef WARP_H +#define WARP_H + extern int errno; #include "config.h" /* generated by Configure script */ +#include <term.h> #include <stdio.h> #include <signal.h> #include <ctype.h> #include <sys/types.h> #include <sys/stat.h> #include <errno.h> +#include <stdlib.h> +#include <string.h> +#include <unistd.h> /* WARPLIB must be readable and writeable by warp, but not by anyone who you * don't trust. In other words, to set up warp so everyone can play and @@ -32,7 +39,7 @@ extern int errno; * access.) */ -#define SAVEDIR "./" +#define SAVEDIR "/var/games" #define NEWSFILE "warp.news" #define HELPFILE "warp.doc" #define LOCKFILE ".warp.lock" @@ -100,6 +107,8 @@ EXT char amb[YSIZE][XSIZE]; #ifdef TERMIO # include <termio.h> +#elif defined TERMIOS +# include <termios.h> #else # include <sgtty.h> #endif @@ -429,10 +438,6 @@ EXT int ambsize; EXT char spbuf[512]; -char *index(), *ttyname(), *malloc(), *ctime(), *strcpy(); -char *getenv(), cmstore(), *tgoto(); -long atol(); - #define Fclose (void)fclose #define Fflush (void)fflush #define Fgets (void)fgets @@ -443,3 +448,5 @@ long atol(); #define Tract (void)tract #define Make_object (void)make_object #define Read_tty (void)read_tty + +#endif