#include "util.h"
#include <stdio.h>
#include <unistd.h>
#include <netdb.h>
#include <string.h>
#include <ctype.h>

void print_hostname(void)
{
  char hostname[255];
  struct hostent *h;

  gethostname(hostname, sizeof(hostname));
  h = gethostbyname(hostname);
  printf("%s\n", (h ? h->h_name : "(none)"));
}

