● 헤더파일/* * tcpecho.c * TCP Echo Client 프로그램 * gcc -o tcpechoc hostname port 번호 * 사용법 : tcpechoc hostname port 번호 */ #include #include #include #include #include #include #include ● struct hostent *hp, *gethostbyname();- hostent는 에 있다.struct hostent{ char *h_name; //공식 도메인 이름 char **h_aliases; //공식 이외 도메인 이름들 int h_addrtype; //주소정보 체계(IPv4: AF_INET, IPv6: AF_INET6) int h_length; //IP주소의 크기를 담는다...