diff options
author | dd <dd@FreeBSD.org> | 2001-05-27 06:28:08 +0000 |
---|---|---|
committer | dd <dd@FreeBSD.org> | 2001-05-27 06:28:08 +0000 |
commit | 3be8c16308af83af5fc9ea91b91e8602c4130081 (patch) | |
tree | fd75c4ed95105a6eabf2746193bca8e213cc66f6 /usr.sbin/kbdcontrol/kbdcontrol.c | |
parent | 7e15f71f4f1c5f94eb545e4a349a6594ca5ccba7 (diff) | |
download | FreeBSD-src-3be8c16308af83af5fc9ea91b91e8602c4130081.zip FreeBSD-src-3be8c16308af83af5fc9ea91b91e8602c4130081.tar.gz |
Instead of defining CONS_CLRHIST if it isn't defined, simply disable
the -c option [when CONS_CLRHIST isn't defined]. This is okay since
the only time CONS_CLRHIST wouldn't be defined is when kbdcontrol is
being built in bootstrap-tools, and -c isn't needed then.
Submitted by: imp
Diffstat (limited to 'usr.sbin/kbdcontrol/kbdcontrol.c')
-rw-r--r-- | usr.sbin/kbdcontrol/kbdcontrol.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.sbin/kbdcontrol/kbdcontrol.c b/usr.sbin/kbdcontrol/kbdcontrol.c index 287b266..577d919 100644 --- a/usr.sbin/kbdcontrol/kbdcontrol.c +++ b/usr.sbin/kbdcontrol/kbdcontrol.c @@ -44,16 +44,12 @@ static const char rcsid[] = #include "lex.h" /* - * PASTE and CONS_CLRHIST are't defined in 4.x, but we need them to - * bridge to 5.0-current so define them here as a stop gap transition - * measure. + * PASTE isn't defined in 4.x, but we need it to bridge to 5.0-current + * so define it here as a stop gap transition measure. */ #ifndef PASTE #define PASTE 0xa3 /* paste from cut-paste buffer */ #endif -#ifndef CONS_CLRHIST -#define CONS_CLRHIST _IO('c', 10) -#endif char ctrl_names[32][4] = { "nul", "soh", "stx", "etx", "eot", "enq", "ack", "bel", @@ -988,8 +984,12 @@ void clear_history() { +#ifdef CONS_CLRHIST if (ioctl(0, CONS_CLRHIST) == -1) warn("clear history buffer"); +#else + warnx("clearing history not supported"); +#endif } static char |