On 01/27/2015 12:00 PM, Daniel Stone wrote:
If the hostname's been truncated, then it's not useful for our purposes.
I would think the truncated hostname would provide more information such
as in an error message. But anyway this could be done this way:
name[sizeof(name)-1] = 0;
gethostname(name, sizeof(name));
/* ignore truncated hostnames: */
if (name[sizeof(name)-1] != 0) name[0] = 0;
_______________________________________________
wayland-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/wayland-devel