add client testing
This commit is contained in:
16
include/client.h
Normal file
16
include/client.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef __CLIENT_H__
|
||||
#define __CLIENT_H__
|
||||
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
#include <netinet/in.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
int test_client_connection(const char *hostname, const char *port);
|
||||
|
||||
#endif
|
||||
@@ -15,6 +15,6 @@
|
||||
// how many pending connections the queue will hold
|
||||
#define BACKLOG 10
|
||||
|
||||
int start_server(void);
|
||||
int start_server(const char *hostname, const char *service);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
// Print every IPs of a hostname
|
||||
// print every IPs of a hostname
|
||||
void print_ips(const char *hostname, const char *port);
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user