Open mfunyu opened 3 months ago
t->icmpfd = socket (PF_INET, SOCK_RAW, protocol->p_proto); if (t->icmpfd < 0 && (errno == EPERM || errno == EACCES)) { /* A subprivileged user on GNU/Linux might be allowed * to create ICMP packets from a datagram socket. * Such packets are always severely crippled. */ errno = 0; t->icmpfd = socket (PF_INET, SOCK_DGRAM, protocol->p_proto); t->no_ident++; /* Recover error message for non-Linux systems. */ if (errno == EPROTONOSUPPORT) errno = EPERM; } if (t->icmpfd < 0) error (EXIT_FAILURE, errno, "socket");