summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dix/dispatch.c5
-rw-r--r--include/os.h4
-rw-r--r--os/auth.c2
-rw-r--r--os/connection.c4
-rw-r--r--os/mitauth.c2
-rw-r--r--os/osdep.h2
-rw-r--r--os/rpcauth.c2
-rw-r--r--os/xdmauth.c4
8 files changed, 13 insertions, 12 deletions
diff --git a/dix/dispatch.c b/dix/dispatch.c
index b39271fd9..048dff652 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -3600,7 +3600,7 @@ ProcInitialConnection(ClientPtr client)
}
static int
-SendConnSetup(ClientPtr client, char *reason)
+SendConnSetup(ClientPtr client, const char *reason)
{
xWindowRoot *root;
int i;
@@ -3699,7 +3699,8 @@ SendConnSetup(ClientPtr client, char *reason)
int
ProcEstablishConnection(ClientPtr client)
{
- char *reason, *auth_proto, *auth_string;
+ const char *reason;
+ char *auth_proto, *auth_string;
xConnClientPrefix *prefix;
REQUEST(xReq);
diff --git a/include/os.h b/include/os.h
index 0b5024156..48ce32962 100644
--- a/include/os.h
+++ b/include/os.h
@@ -127,7 +127,7 @@ extern _X_EXPORT void CloseWellKnownConnections(void);
extern _X_EXPORT XID AuthorizationIDOfClient(ClientPtr /*client*/);
-extern _X_EXPORT char *ClientAuthorized(
+extern _X_EXPORT const char *ClientAuthorized(
ClientPtr /*client*/,
unsigned int /*proto_n*/,
char* /*auth_proto*/,
@@ -415,7 +415,7 @@ extern _X_EXPORT XID CheckAuthorization(
unsigned int /*datalength*/,
const char * /*data*/,
ClientPtr /*client*/,
- char ** /*reason*/
+ const char ** /*reason*/
);
extern _X_EXPORT void ResetAuthorization(void);
diff --git a/os/auth.c b/os/auth.c
index 9d36249f2..6669c148e 100644
--- a/os/auth.c
+++ b/os/auth.c
@@ -163,7 +163,7 @@ CheckAuthorization (
unsigned int data_length,
const char *data,
ClientPtr client,
- char **reason) /* failure message. NULL for default msg */
+ const char **reason) /* failure message. NULL for default msg */
{
int i;
struct stat buf;
diff --git a/os/connection.c b/os/connection.c
index 6f480deb6..8a677a7ef 100644
--- a/os/connection.c
+++ b/os/connection.c
@@ -629,7 +629,7 @@ AuthorizationIDOfClient(ClientPtr client)
*
*****************************************************************/
-char *
+const char *
ClientAuthorized(ClientPtr client,
unsigned int proto_n, char *auth_proto,
unsigned int string_n, char *auth_string)
@@ -639,7 +639,7 @@ ClientAuthorized(ClientPtr client,
int family;
int fromlen;
XID auth_id;
- char *reason = NULL;
+ const char *reason = NULL;
XtransConnInfo trans_conn;
priv = (OsCommPtr)client->osPrivate;
diff --git a/os/mitauth.c b/os/mitauth.c
index 4b8f6e978..477736ee8 100644
--- a/os/mitauth.c
+++ b/os/mitauth.c
@@ -76,7 +76,7 @@ MitCheckCookie (
unsigned short data_length,
const char *data,
ClientPtr client,
- char **reason)
+ const char **reason)
{
struct auth *auth;
diff --git a/os/osdep.h b/os/osdep.h
index 72bd7d762..71a7e44e3 100644
--- a/os/osdep.h
+++ b/os/osdep.h
@@ -137,7 +137,7 @@ typedef void (*AuthInitFunc) (AuthInitArgs);
#define AuthAddCArgs unsigned short data_length, const char *data, XID id
typedef int (*AuthAddCFunc) (AuthAddCArgs);
-#define AuthCheckArgs unsigned short data_length, const char *data, ClientPtr client, char **reason
+#define AuthCheckArgs unsigned short data_length, const char *data, ClientPtr client, const char **reason
typedef XID (*AuthCheckFunc) (AuthCheckArgs);
#define AuthFromIDArgs XID id, unsigned short *data_lenp, char **datap
diff --git a/os/rpcauth.c b/os/rpcauth.c
index 989a49a06..63b97b675 100644
--- a/os/rpcauth.c
+++ b/os/rpcauth.c
@@ -128,7 +128,7 @@ static char rpc_error[MAXNETNAMELEN+50];
_X_HIDDEN XID
SecureRPCCheck (unsigned short data_length, const char *data,
- ClientPtr client, char **reason)
+ ClientPtr client, const char **reason)
{
char *fullname;
diff --git a/os/xdmauth.c b/os/xdmauth.c
index b8cbada18..733fda504 100644
--- a/os/xdmauth.c
+++ b/os/xdmauth.c
@@ -248,7 +248,7 @@ XdmClientAuthTimeout (long now)
static XdmClientAuthPtr
XdmAuthorizationValidate (unsigned char *plain, int length,
- XdmAuthKeyPtr rho, ClientPtr xclient, char **reason)
+ XdmAuthKeyPtr rho, ClientPtr xclient, const char **reason)
{
XdmClientAuthPtr client, existing;
long now;
@@ -376,7 +376,7 @@ XdmAddCookie (unsigned short data_length, const char *data, XID id)
XID
XdmCheckCookie (unsigned short cookie_length, const char *cookie,
- ClientPtr xclient, char **reason)
+ ClientPtr xclient, const char **reason)
{
XdmAuthorizationPtr auth;
XdmClientAuthPtr client;