summaryrefslogtreecommitdiff
path: root/Xtranssock.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2011-09-25 11:18:26 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2011-10-01 08:55:53 -0700
commiteb9a8904fbef61a57ff01c90627ead57055ed62b (patch)
tree1cd0de80e0b9db38aa1b33cf4f6c9dc9bc4e2e5f /Xtranssock.c
parent4e610d4bbcf29cca9dc5dbad29ca820996aaa8c7 (diff)
Add const attributes to fix gcc -Wwrite-strings warnings
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'Xtranssock.c')
-rw-r--r--Xtranssock.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/Xtranssock.c b/Xtranssock.c
index 775a7f9..1275196 100644
--- a/Xtranssock.c
+++ b/Xtranssock.c
@@ -172,7 +172,7 @@ from the copyright holders.
*/
typedef struct _Sockettrans2dev {
- char *transname;
+ const char *transname;
int family;
int devcotsname;
int devcltsname;
@@ -254,7 +254,7 @@ static int TRANS(SocketINETClose) (XtransConnInfo ciptr);
*/
static int
-TRANS(SocketSelectFamily) (int first, char *family)
+TRANS(SocketSelectFamily) (int first, const char *family)
{
int i;
@@ -538,8 +538,8 @@ TRANS(SocketReopen) (int i _X_UNUSED, int type, int fd, char *port)
#ifdef TRANS_CLIENT
static XtransConnInfo
-TRANS(SocketOpenCOTSClientBase) (char *transname, char *protocol,
- char *host, char *port, int previndex)
+TRANS(SocketOpenCOTSClientBase) (const char *transname, const char *protocol,
+ const char *host, const char *port, int previndex)
{
XtransConnInfo ciptr;
int i = previndex;
@@ -2248,7 +2248,7 @@ TRANS(SocketUNIXCloseForCloning) (XtransConnInfo ciptr)
#ifdef TCPCONN
# ifdef TRANS_SERVER
-static char* tcp_nolisten[] = {
+static const char* tcp_nolisten[] = {
"inet",
#if defined(IPv6) && defined(AF_INET6)
"inet6",