diff --git a/client.c b/client.c index f269b4e..49455dc 100644 --- a/client.c +++ b/client.c @@ -6,7 +6,6 @@ * @brief Client for OSUE exercise 1B `Battleship'. */ -// IO, C standard library, POSIX API, data types: #include #include #include @@ -15,30 +14,24 @@ #include #include -// Assertions, errors, signals: #include #include #include -// Time: #include -// Sockets, TCP, ... : #include #include #include #include -// stuff shared by client and server: #include "common.h" -// Static variables for things you might want to access from several functions: -static const char *port = DEFAULT_PORT; // the port to bind to +static const char *port = DEFAULT_PORT; -// Static variables for resources that should be freed before exiting: -static struct addrinfo *ai = NULL; // addrinfo struct +static struct addrinfo *ai = NULL; static char *hostname = NULL; -static int sockfd = -1; // socket file descriptor +static int sockfd = -1; static char* pname; static int field[MAP_SIZE][MAP_SIZE];