diff options
author | ache <ache@FreeBSD.org> | 1995-08-04 08:05:18 +0000 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 1995-08-04 08:05:18 +0000 |
commit | 2e718b4cda54fcd730fbd6065ecc66b8494eeab2 (patch) | |
tree | 6897bfca475cf2fdb1cbe1f858a1c4eb31b1109c /usr.bin | |
parent | 7c489bde4376762aba4b947a3ae6b6c9b8075645 (diff) | |
download | FreeBSD-src-2e718b4cda54fcd730fbd6065ecc66b8494eeab2.zip FreeBSD-src-2e718b4cda54fcd730fbd6065ecc66b8494eeab2.tar.gz |
Add missing ospeed initialization.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/ncftp/main.c | 12 | ||||
-rw-r--r-- | usr.bin/ncftp/sys.h | 6 |
2 files changed, 15 insertions, 3 deletions
diff --git a/usr.bin/ncftp/main.c b/usr.bin/ncftp/main.c index b0a11c4..80b5015 100644 --- a/usr.bin/ncftp/main.c +++ b/usr.bin/ncftp/main.c @@ -29,6 +29,10 @@ # endif #endif /* CURSES */ +#if defined(CURSES) && defined(SGTTYB) +# include <sgtty.h> +#endif + #include "util.h" #include "cmds.h" #include "main.h" @@ -1104,6 +1108,10 @@ int termcap_get(char **dest, char *attr) void termcap_init(void) { char *term; +#ifdef SGTTYB + struct sgttyb ttyb; + extern short ospeed; +#endif if ((term = getenv("TERM")) == NULL) { term = "dumb"; /* TAR */ @@ -1123,6 +1131,10 @@ void termcap_init(void) tcl_bold = strlen(tcap_boldface); tcl_uline = strlen(tcap_underline); tcl_rev = strlen(tcap_reverse); +#ifdef SGTTYB + if (ioctl(fileno(stdout), TIOCGETP, &ttyb) == 0) + ospeed = ttyb.sg_ospeed; +#endif } } /* termcap_init */ diff --git a/usr.bin/ncftp/sys.h b/usr.bin/ncftp/sys.h index d009caa..66ed9cd 100644 --- a/usr.bin/ncftp/sys.h +++ b/usr.bin/ncftp/sys.h @@ -446,10 +446,10 @@ extern int errno; # ifndef SYSDIRH # define SYSDIRH 1 # endif -# ifndef SGTTYB -# define SGTTYB -# endif # endif +# ifndef SGTTYB +# define SGTTYB +# endif #endif /* |