summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorache <ache@FreeBSD.org>2000-06-05 20:54:46 +0000
committerache <ache@FreeBSD.org>2000-06-05 20:54:46 +0000
commitaf7185e20dff77fb7962e8a66f6b2e1d9cf11a95 (patch)
tree9410f4110adb85d4bc7deb1c7418fe37bf4a947d /bin
parent4f7cf520713444ac89829ff92e6ba33b17e39ac6 (diff)
downloadFreeBSD-src-af7185e20dff77fb7962e8a66f6b2e1d9cf11a95.zip
FreeBSD-src-af7185e20dff77fb7962e8a66f6b2e1d9cf11a95.tar.gz
Get rid of curses completely - use tgoto instead of tparm
Diffstat (limited to 'bin')
-rw-r--r--bin/ls/print.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/bin/ls/print.c b/bin/ls/print.c
index 1cdbf4f..fc9bf93 100644
--- a/bin/ls/print.c
+++ b/bin/ls/print.c
@@ -59,7 +59,6 @@ static const char rcsid[] =
#ifdef COLORLS
#include <ctype.h>
#include <termcap.h>
-#include <term.h> /* for tparm */
#include <signal.h>
#endif
@@ -371,14 +370,14 @@ printcolor(c)
char *ansiseq;
if (colors[c][0] != -1) {
- ansiseq = tparm(ansi_fgcol, colors[c][0]);
- if (ansiseq)
+ ansiseq = tgoto(ansi_fgcol, 0, colors[c][0]);
+ if (ansiseq && *ansiseq != 'O') /* "OOPS" */
tputs(ansiseq, 1, putch);
}
if (colors[c][1] != -1) {
- ansiseq = tparm(ansi_bgcol, colors[c][1]);
- if (ansiseq)
+ ansiseq = tgoto(ansi_bgcol, 0, colors[c][1]);
+ if (ansiseq && *ansiseq != 'O') /* "OOPS" */
tputs(ansiseq, 1, putch);
}
}
OpenPOWER on IntegriCloud