removed fcntl for non blocking IO: old artefact from the ping copy/paste

This commit is contained in:
Jack Halford 2017-05-14 22:30:39 +02:00
parent adc4965e38
commit b042d94bf6
3 changed files with 4 additions and 2 deletions

2
traceroute/.gitignore vendored Normal file
View file

@ -0,0 +1,2 @@
traceroute
ft_traceroute

Binary file not shown.

View file

@ -80,8 +80,8 @@ int traceroute(struct sockaddr_in *dest)
perror("socket"); perror("socket");
return (1); return (1);
} }
if (fcntl(sd, F_SETFL, O_NONBLOCK) != 0) /* if (fcntl(sd, F_SETFL, O_NONBLOCK) != 0) */
perror("Request non blocking IO"); /* perror("Request non blocking IO"); */
for (ttl = 1; ttl < 255; ttl++) for (ttl = 1; ttl < 255; ttl++)
{ {
if (setsockopt(sd, 0, IP_TTL, &ttl, sizeof(ttl)) != 0) if (setsockopt(sd, 0, IP_TTL, &ttl, sizeof(ttl)) != 0)