On 01/10/2009 07:12, Jon TURNEY wrote:
+  if (TransIsListening("local"))
+    {
+      snprintf(szDisplay, 512, ":%s.%d", display, screen);
+    }
+  else if (TransIsListening("inet"))
+    {
+      snprintf(szDisplay, 512, "127.0.0.1:%s.%d", display, screen);
+    }
+  else if (TransIsListening("inet6"))
+    {
+      snprintf(szDisplay, 512, "::1:%s.%d", display, screen);
+    }

Perhaps we should be giving priority to inet6 over inet if it's available?

+  else
+    {
+      // this can't happen!
+      snprintf(szDisplay, 512, "localhost:%s.%d", display, screen);
+    }

If this can't happen, an ErrorF would be appropriate.


Yaakov
Cygwin/X

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://x.cygwin.com/docs/
FAQ:                   http://x.cygwin.com/docs/faq/

Reply via email to