summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorBrian Cameron <Brian.Cameron@sun.com>2010-01-13 09:33:23 -0500
committerRay Strode <rstrode@redhat.com>2010-01-13 09:33:23 -0500
commite533f4b72568cdc3d7f7ec6cec09d9392b11d54c (patch)
tree56979113260da86ace65069bb43ff33acce1d30e /common
parent4b1263a30b2ffa9c4df8d69f857d4eefce289f55 (diff)
downloadgdm-e533f4b72568cdc3d7f7ec6cec09d9392b11d54c.tar.gz
Fix up XDMCP for Solaris
After doing further testing, I notice that XDMCP still does not work on Solaris. This commit fixes: - In gdm-address.c, there was a problem where a failure in gdm_address_get_hostname could cause an infinite loop since it would call gdm_address_debug, which would then call gdm_address_get_hostname again. I fixed this by making gdm_address_debug call a private _gdm_address_debug function and gdm_address_get_hostname calls _gdm_adress_debug rather than gdm_address_debug. - Two calls in gdm-address.c were using "sizeof (struct sockaddr_storage)" and changing this to "(int) gdm_sockaddr_len (address->ss)" works better. This is the same issue as fixed in the previous patch. I just missed these spots before. - In daemon/gdm-xdmcp-display-factory.c in the on_hostname_selected() function it is necessary to set hints.ai_socktype to "SOCK_DGRAM" or else I would get this error: WARNING: Unable get address: service name not available for the specified socket type - In daemon/gdm-xdmcp-display-factory.c in the decode_packet() function and in gui/simple-chooser/gdm-host-chooser-widget.c it is necessary to set ss_len to "gdm_sockaddr_len (&clnt_ss)" instead of "sizeof (clnt_ss)". - In gui/simple-chooser/gdm-host-chooser-widget.c in find_broacast_address it is also necessary to check for "(errno != ENXIO)". See https://bugzilla.gnome.org/show_bug.cgi?id=494817
Diffstat (limited to 'common')
-rw-r--r--common/gdm-address.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/gdm-address.c b/common/gdm-address.c
index 2426b9c3..ce87d98b 100644
--- a/common/gdm-address.c
+++ b/common/gdm-address.c
@@ -270,7 +270,7 @@ gdm_address_get_hostname (GdmAddress *address,
host [0] = '\0';
res = getnameinfo ((const struct sockaddr *)address->ss,
- sizeof (struct sockaddr_storage),
+ (int) gdm_sockaddr_len (address->ss),
host, sizeof (host),
NULL, 0,
0);