summaryrefslogtreecommitdiff
path: root/os/xdmcp.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2011-12-12 16:49:33 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2011-12-12 17:03:10 -0800
commit83ac9502ea9f1dedf3a8002745668af16bb1f2af (patch)
treeed21ab9adbdd74e3a65998519ab87f83b9b78948 /os/xdmcp.c
parent3839d1480877818f3ccc04e25237d853bab210c3 (diff)
xdmcp.c: fix three small const warnings
xdmcp.c:63:36: warning: initialization discards qualifiers from pointer target type xdmcp.c: In function 'XdmcpRegisterConnection': xdmcp.c:482:8: warning: cast discards qualifiers from pointer target type xdmcp.c:482:8: warning: cast discards qualifiers from pointer target type xdmcp.c:482:8: warning: cast discards qualifiers from pointer target type xdmcp.c: In function 'get_mcast_options': xdmcp.c:1596:21: warning: initialization discards qualifiers from pointer target type Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jamey Sharp <jamey@minilop.net> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'os/xdmcp.c')
-rw-r--r--os/xdmcp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/os/xdmcp.c b/os/xdmcp.c
index 46440718c..77f02da91 100644
--- a/os/xdmcp.c
+++ b/os/xdmcp.c
@@ -60,7 +60,7 @@
#define X_INCLUDE_NETDB_H
#include <X11/Xos_r.h>
-static char *defaultDisplayClass = COMPILEDDISPLAYCLASS;
+static const char *defaultDisplayClass = COMPILEDDISPLAYCLASS;
static int xdmcpSocket, sessionSocket;
static xdmcp_states state;
@@ -479,7 +479,7 @@ XdmcpRegisterConnection (
if (SOCKADDR_FAMILY(FromAddress) == AF_INET6) {
fromAddr = &((struct sockaddr_in6 *)&FromAddress)->sin6_addr;
} else if ((SOCKADDR_FAMILY(FromAddress) == AF_INET) &&
- IN6_IS_ADDR_V4MAPPED((struct in6_addr *) address)) {
+ IN6_IS_ADDR_V4MAPPED((const struct in6_addr *) address)) {
fromAddr = &((struct sockaddr_in *)&FromAddress)->sin_addr;
regAddr = &((struct sockaddr_in6 *)&address)->sin6_addr.s6_addr[12];
regAddrlen = sizeof(struct in_addr);
@@ -1593,7 +1593,7 @@ get_fromaddr_by_name(
static int
get_mcast_options(int argc, char **argv, int i)
{
- char *address = XDM_DEFAULT_MCAST_ADDR6;
+ const char *address = XDM_DEFAULT_MCAST_ADDR6;
int hopcount = 1;
struct addrinfo hints;
char portstr[6];