summaryrefslogtreecommitdiffstats
path: root/lib/libtermcap/tgoto.c
diff options
context:
space:
mode:
authorache <ache@FreeBSD.org>1995-08-05 21:22:07 +0000
committerache <ache@FreeBSD.org>1995-08-05 21:22:07 +0000
commit100e6f311c5d20fdb09afe48750d3d733c8b8e45 (patch)
tree84255860ff0aa7fd3bacde0ab4494a6ab882406e /lib/libtermcap/tgoto.c
parentc426abc4240ef56049117a4cc11d9db6a62c0db1 (diff)
downloadFreeBSD-src-100e6f311c5d20fdb09afe48750d3d733c8b8e45.zip
FreeBSD-src-100e6f311c5d20fdb09afe48750d3d733c8b8e45.tar.gz
Do a little trick which covers 99% cases: initialize ospeed
variable directly in tgetent by stderr or stdout output speed. It helps hide in non-standard __set_ospeed function and remove it from other sources (coming soon). Do prototype cleanup too.
Diffstat (limited to 'lib/libtermcap/tgoto.c')
-rw-r--r--lib/libtermcap/tgoto.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libtermcap/tgoto.c b/lib/libtermcap/tgoto.c
index c4dd9d7..e28a85c 100644
--- a/lib/libtermcap/tgoto.c
+++ b/lib/libtermcap/tgoto.c
@@ -35,6 +35,8 @@
static char sccsid[] = "@(#)tgoto.c 8.1 (Berkeley) 6/4/93";
#endif /* not lint */
+#include "termcap.h"
+
#define CTRL(c) ((c) & 037)
#define MAXRETURNSIZE 64
@@ -67,13 +69,11 @@ char *BC;
* all other characters are ``self-inserting''.
*/
char *
-tgoto(CM, destcol, destline)
- char *CM;
- int destcol, destline;
+tgoto(const char *CM, int destcol, int destline)
{
static char result[MAXRETURNSIZE];
static char added[10];
- char *cp = CM;
+ const char *cp = CM;
register char *dp = result;
register int c;
int oncol = 0;
OpenPOWER on IntegriCloud