I had a problem with a particular host not showing up in XDMCP chooser lists, and also being unable to connect to it via Xnest. I found that gdm-binary was connected to the correct port: netstat -l -udp -p I found that the connection inquiries were being delivered: tcpdump -i any "udp and port 177" However, there were no replies. After downloading the gdm source code, enabling debugging, and inserting extra debug statements, I found that there is a recursion in the add_local_siocgifconf function in gdm-address.c . It calls gdm_address_debug, which in turn calls add_local_siocgifconf again. It appears that the call to gdm_address_debug is intended to display additional debug information, and is not critical to the functioning of the program. I found the problem in version 2.30.4 of gdm (RHEL6.3), but the line that causes the recursion is still present in your git repository. The root cause of the problem was a misconfigured /etc/resolv.conf . It was pointing to defunct nameservers. We didn't notice, because all the servers that are normally used are looked up via nis. Only gdm-binary XDMCP was doing lookups on our Windows boxes, which are looked up via DNS, which in this case, was failing. This causes gdm_address_get_hostname to call _gdm_address_debug, which in turn causes the recursion. Please find debug log attached. The integer index in the function call traces indicates the function recursion depth. The trace clearly shows that the recursion does not terminate. I have truncated the log at a depth of 80 calls to fit within the attachment limit size. To fix the recursion, more care must be taken to break the interactions between add_local_siogifconf -> gdm_address_debug gdm_address_get_hostname -> _gdm_address_debug I suspect that this will require a careful restructure of the code. It would have been instructive in diagnosing the root problem if gdm_address_get_hostname had printed out what it was trying to look up when the lookup failed. I can see that the code was trying to do that, but it failed to print out any useful name or IP address due to the recursion. If a useful name had been printed out, I would have found the root cause (misconfigured resolv.conf) 2 days earlier. Please note that I have also reported this bug in RedHat's bugzilla at https://bugzilla.redhat.com/show_bug.cgi?id=1030163 Regards, Ben Stanley.
Attachment:
gdm-binary.broken.log
Description: Text Data