diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-09-25 11:18:26 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-10-01 08:55:53 -0700 |
commit | eb9a8904fbef61a57ff01c90627ead57055ed62b (patch) | |
tree | 1cd0de80e0b9db38aa1b33cf4f6c9dc9bc4e2e5f /Xtrans.c | |
parent | 4e610d4bbcf29cca9dc5dbad29ca820996aaa8c7 (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 'Xtrans.c')
-rw-r--r-- | Xtrans.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -150,7 +150,7 @@ TRANS(FreeConnInfo) (XtransConnInfo ciptr) #define PROTOBUFSIZE 20 static Xtransport * -TRANS(SelectTransport) (char *protocol) +TRANS(SelectTransport) (const char *protocol) { char protobuf[PROTOBUFSIZE]; @@ -203,7 +203,8 @@ TRANS(ParseAddress) (char *address, char **protocol, char **host, char **port) */ char *mybuf, *tmpptr; - char *_protocol, *_host, *_port; + const char *_protocol; + char *_host, *_port; char hostnamebuf[256]; int _host_len; @@ -759,7 +760,7 @@ TRANS(CreateListener) (XtransConnInfo ciptr, char *port, unsigned int flags) } int -TRANS(NoListen) (char * protocol) +TRANS(NoListen) (const char * protocol) { Xtransport *trans; |