summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2007-11-26 16:56:43 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2007-11-26 16:56:43 +0000
commit36460865e8900119b203ce0444196799e44ade5b (patch)
tree0849bd8e3065b22c6f234a2dc971895b4a96c29f /sys
parent4c8ec346c37b4e89be57a88234cc8f9aaee197b7 (diff)
Constify the output of the emulops translate() function, as well as the
various tables they use.
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/wscons/wsdisplay.c4
-rw-r--r--sys/dev/wscons/wsemul_dumb.c6
-rw-r--r--sys/dev/wscons/wsemul_sun.c10
-rw-r--r--sys/dev/wscons/wsemul_vt100_keys.c10
-rw-r--r--sys/dev/wscons/wsemul_vt100var.h4
-rw-r--r--sys/dev/wscons/wsemulvar.h4
6 files changed, 19 insertions, 19 deletions
diff --git a/sys/dev/wscons/wsdisplay.c b/sys/dev/wscons/wsdisplay.c
index 3a0fa809971..e89b5249496 100644
--- a/sys/dev/wscons/wsdisplay.c
+++ b/sys/dev/wscons/wsdisplay.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsdisplay.c,v 1.83 2007/11/25 19:11:42 miod Exp $ */
+/* $OpenBSD: wsdisplay.c,v 1.84 2007/11/26 16:56:41 miod Exp $ */
/* $NetBSD: wsdisplay.c,v 1.82 2005/02/27 00:27:52 perry Exp $ */
/*
@@ -1552,7 +1552,7 @@ wsdisplay_kbdinput(struct device *dev, keysym_t ks)
{
struct wsdisplay_softc *sc = (struct wsdisplay_softc *)dev;
struct wsscreen *scr;
- char *dp;
+ const char *dp;
int count;
struct tty *tp;
diff --git a/sys/dev/wscons/wsemul_dumb.c b/sys/dev/wscons/wsemul_dumb.c
index 983b15557a3..7ed932d355b 100644
--- a/sys/dev/wscons/wsemul_dumb.c
+++ b/sys/dev/wscons/wsemul_dumb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsemul_dumb.c,v 1.5 2007/11/25 19:11:42 miod Exp $ */
+/* $OpenBSD: wsemul_dumb.c,v 1.6 2007/11/26 16:56:42 miod Exp $ */
/* $NetBSD: wsemul_dumb.c,v 1.7 2000/01/05 11:19:36 drochner Exp $ */
/*
@@ -48,7 +48,7 @@ void *wsemul_dumb_attach(int console, const struct wsscreen_descr *,
void *, int, int, void *, long);
void wsemul_dumb_output(void *cookie, const u_char *data, u_int count,
int);
-int wsemul_dumb_translate(void *cookie, keysym_t, char **);
+int wsemul_dumb_translate(void *cookie, keysym_t, const char **);
void wsemul_dumb_detach(void *cookie, u_int *crowp, u_int *ccolp);
void wsemul_dumb_resetop(void *, enum wsemul_resetops);
@@ -230,7 +230,7 @@ int
wsemul_dumb_translate(cookie, in, out)
void *cookie;
keysym_t in;
- char **out;
+ const char **out;
{
return (0);
}
diff --git a/sys/dev/wscons/wsemul_sun.c b/sys/dev/wscons/wsemul_sun.c
index 2558d4bcc0a..814d10eac4b 100644
--- a/sys/dev/wscons/wsemul_sun.c
+++ b/sys/dev/wscons/wsemul_sun.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsemul_sun.c,v 1.21 2007/11/25 19:11:42 miod Exp $ */
+/* $OpenBSD: wsemul_sun.c,v 1.22 2007/11/26 16:56:42 miod Exp $ */
/* $NetBSD: wsemul_sun.c,v 1.11 2000/01/05 11:19:36 drochner Exp $ */
/*
@@ -59,7 +59,7 @@ void *wsemul_sun_cnattach(const struct wsscreen_descr *, void *,
void *wsemul_sun_attach(int, const struct wsscreen_descr *,
void *, int, int, void *, long);
void wsemul_sun_output(void *, const u_char *, u_int, int);
-int wsemul_sun_translate(void *, keysym_t, char **);
+int wsemul_sun_translate(void *, keysym_t, const char **);
void wsemul_sun_detach(void *, u_int *, u_int *);
void wsemul_sun_resetop(void *, enum wsemul_resetops);
@@ -738,7 +738,7 @@ wsemul_sun_selectattribute(edp, flags, fgcol, bgcol, attr, bkgdattr)
return (0);
}
-static char *sun_fkeys[] = {
+static const char *sun_fkeys[] = {
"\033[224z", /* F1 */
"\033[225z",
"\033[226z",
@@ -753,7 +753,7 @@ static char *sun_fkeys[] = {
"\033[235z", /* F12 */
};
-static char *sun_lkeys[] = {
+static const char *sun_lkeys[] = {
"\033[207z", /* KS_Help */
NULL, /* KS_Execute */
"\033[200z", /* KS_Find */
@@ -772,7 +772,7 @@ int
wsemul_sun_translate(cookie, in, out)
void *cookie;
keysym_t in;
- char **out;
+ const char **out;
{
static char c;
diff --git a/sys/dev/wscons/wsemul_vt100_keys.c b/sys/dev/wscons/wsemul_vt100_keys.c
index ffbc583f047..99cb873ab39 100644
--- a/sys/dev/wscons/wsemul_vt100_keys.c
+++ b/sys/dev/wscons/wsemul_vt100_keys.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsemul_vt100_keys.c,v 1.2 2004/04/02 04:39:51 deraadt Exp $ */
+/* $OpenBSD: wsemul_vt100_keys.c,v 1.3 2007/11/26 16:56:42 miod Exp $ */
/* $NetBSD: wsemul_vt100_keys.c,v 1.3 1999/04/22 20:06:02 mycroft Exp $ */
/*
@@ -35,7 +35,7 @@
#include <dev/wscons/wsksymdef.h>
#include <dev/wscons/wsemul_vt100var.h>
-static char *vt100_fkeys[] = {
+static const char *vt100_fkeys[] = {
"\033[11~", /* F1 */
"\033[12~",
"\033[13~", /* F1-F5 normally don't send codes */
@@ -58,14 +58,14 @@ static char *vt100_fkeys[] = {
"\033[34~", /* F20 */
};
-static char *vt100_pfkeys[] = {
+static const char *vt100_pfkeys[] = {
"\033OP", /* PF1 */
"\033OQ",
"\033OR",
"\033OS", /* PF4 */
};
-static char *vt100_numpad[] = {
+static const char *vt100_numpad[] = {
"\033Op", /* KP 0 */
"\033Oq", /* KP 1 */
"\033Or", /* KP 2 */
@@ -82,7 +82,7 @@ int
wsemul_vt100_translate(cookie, in, out)
void *cookie;
keysym_t in;
- char **out;
+ const char **out;
{
struct wsemul_vt100_emuldata *edp = cookie;
static char c;
diff --git a/sys/dev/wscons/wsemul_vt100var.h b/sys/dev/wscons/wsemul_vt100var.h
index 69b921b4132..ae706a25c31 100644
--- a/sys/dev/wscons/wsemul_vt100var.h
+++ b/sys/dev/wscons/wsemul_vt100var.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsemul_vt100var.h,v 1.6 2007/01/07 13:31:36 miod Exp $ */
+/* $OpenBSD: wsemul_vt100var.h,v 1.7 2007/11/26 16:56:42 miod Exp $ */
/* $NetBSD: wsemul_vt100var.h,v 1.5 2000/04/28 21:56:17 mycroft Exp $ */
/*
@@ -135,7 +135,7 @@ void wsemul_vt100_el(struct wsemul_vt100_emuldata *, int);
void wsemul_vt100_handle_csi(struct wsemul_vt100_emuldata *, u_char);
void wsemul_vt100_handle_dcs(struct wsemul_vt100_emuldata *);
-int wsemul_vt100_translate(void *cookie, keysym_t, char **);
+int wsemul_vt100_translate(void *cookie, keysym_t, const char **);
void vt100_initchartables(struct wsemul_vt100_emuldata *);
int vt100_setnrc(struct wsemul_vt100_emuldata *, int);
diff --git a/sys/dev/wscons/wsemulvar.h b/sys/dev/wscons/wsemulvar.h
index 94e3f505509..0084a76affa 100644
--- a/sys/dev/wscons/wsemulvar.h
+++ b/sys/dev/wscons/wsemulvar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsemulvar.h,v 1.8 2007/11/25 19:11:43 miod Exp $ */
+/* $OpenBSD: wsemulvar.h,v 1.9 2007/11/26 16:56:42 miod Exp $ */
/* $NetBSD: wsemulvar.h,v 1.6 1999/01/17 15:46:15 drochner Exp $ */
/*
@@ -50,7 +50,7 @@ struct wsemul_ops {
int, int, void *, long);
void (*output)(void *cookie, const u_char *data, u_int count,
int);
- int (*translate)(void *, keysym_t, char **);
+ int (*translate)(void *, keysym_t, const char **);
void (*detach)(void *cookie, u_int *crow, u_int *ccol);
void (*reset)(void *, enum wsemul_resetops);
};