Continued working on retrieving IP address from message
This commit is contained in:
8
main.c
8
main.c
@@ -66,6 +66,14 @@ int main() {
|
||||
} else {
|
||||
if (dest_address[i] == NULL) {
|
||||
dest_address[i] = fetch_address(buffer);
|
||||
if (dest_address[i] == NULL) {
|
||||
printf("Invalid message format\n");
|
||||
exit(241);
|
||||
}
|
||||
if (check_ip_ver(dest_address[i]) == -1) {
|
||||
printf("Invalid address: %s\n",dest_address[i]);
|
||||
exit(242);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user