Module Name: xsrc
Committed By: mrg
Date: Tue Aug 16 06:29:28 UTC 2016
Modified Files:
xsrc/external/mit/xf86-input-ws/dist/src: ws.c ws.h
Log Message:
apply const from xorg-server 1.18
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 xsrc/external/mit/xf86-input-ws/dist/src/ws.c
cvs rdiff -u -r1.1.1.2 -r1.2 xsrc/external/mit/xf86-input-ws/dist/src/ws.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: xsrc/external/mit/xf86-input-ws/dist/src/ws.c
diff -u xsrc/external/mit/xf86-input-ws/dist/src/ws.c:1.8 xsrc/external/mit/xf86-input-ws/dist/src/ws.c:1.9
--- xsrc/external/mit/xf86-input-ws/dist/src/ws.c:1.8 Mon Sep 26 18:04:36 2011
+++ xsrc/external/mit/xf86-input-ws/dist/src/ws.c Tue Aug 16 06:29:28 2016
@@ -132,6 +132,7 @@ wsPreInit12(InputDriverPtr drv, InputInf
WSDevicePtr priv;
MessageType buttons_from = X_CONFIG;
char *s;
+ const char *cs;
int rc;
priv = (WSDevicePtr)calloc(1, sizeof(WSDeviceRec));
@@ -235,22 +236,22 @@ wsPreInit12(InputDriverPtr drv, InputInf
}
priv->inv_x = 0;
priv->inv_y = 0;
- s = xf86FindOptionValue(pInfo->options, "Rotate");
- if (s) {
- if (xf86NameCmp(s, "CW") == 0) {
+ cs = xf86FindOptionValue(pInfo->options, "Rotate");
+ if (cs) {
+ if (xf86NameCmp(cs, "CW") == 0) {
priv->inv_x = 1;
priv->inv_y = 0;
priv->swap_axes = 1;
- } else if (xf86NameCmp(s, "CCW") == 0) {
+ } else if (xf86NameCmp(cs, "CCW") == 0) {
priv->inv_x = 0;
priv->inv_y = 1;
priv->swap_axes = 1;
- } else if (xf86NameCmp(s, "UD") == 0) {
+ } else if (xf86NameCmp(cs, "UD") == 0) {
priv->inv_x = 1;
priv->inv_y = 1;
} else {
xf86Msg(X_ERROR, "\"%s\" is not a valid value "
- "for Option \"Rotate\"\n", s);
+ "for Option \"Rotate\"\n", cs);
xf86Msg(X_ERROR, "Valid options are \"CW\", \"CCW\","
" or \"UD\"\n");
}
Index: xsrc/external/mit/xf86-input-ws/dist/src/ws.h
diff -u xsrc/external/mit/xf86-input-ws/dist/src/ws.h:1.1.1.2 xsrc/external/mit/xf86-input-ws/dist/src/ws.h:1.2
--- xsrc/external/mit/xf86-input-ws/dist/src/ws.h:1.1.1.2 Tue Aug 2 09:28:21 2011
+++ xsrc/external/mit/xf86-input-ws/dist/src/ws.h Tue Aug 16 06:29:28 2016
@@ -33,7 +33,7 @@ extern int ws_debug_level;
#define NUMEVENTS 16 /* max # of ws events to read at once */
typedef struct WSDevice {
- char *devName; /* device name */
+ const char *devName; /* device name */
int type; /* ws device type */
unsigned int buttons; /* # of buttons */
unsigned int lastButtons; /* last state of buttons */