system/ping and ping6: Fix a typo and also a place where = used when == intended.
This commit is contained in:
parent
749ea9e881
commit
bf9bc28fcf
@ -139,7 +139,7 @@ static int ping_gethostip(FAR char *hostname, FAR struct ping_info_s *info)
|
||||
nerr("ERROR: gethostbyname failed: %d\n", h_errno);
|
||||
return -ENOENT;
|
||||
}
|
||||
else if (he->h_addrtype = AF_INET)
|
||||
else if (he->h_addrtype == AF_INET)
|
||||
{
|
||||
memcpy(&info->dest, he->h_addr, sizeof(in_addr_t));
|
||||
}
|
||||
@ -425,7 +425,7 @@ static void show_usage(FAR const char *progname, int exitcode)
|
||||
ICMP_NPINGS);
|
||||
printf(" -i <interval> is the default delay between pings (milliseconds).\n");
|
||||
printf(" Default %d.\n", ICMP_POLL_DELAY);
|
||||
printf(" -h shows this text an exits.\n");
|
||||
printf(" -h shows this text and exits.\n");
|
||||
exit(exitcode);
|
||||
}
|
||||
|
||||
|
@ -438,7 +438,7 @@ static void show_usage(FAR const char *progname, int exitcode)
|
||||
ICMPv6_NPINGS);
|
||||
printf(" -i <interval> is the default delay between pings (milliseconds).\n");
|
||||
printf(" Default %d.\n", ICMPv6_POLL_DELAY);
|
||||
printf(" -h shows this text an exits.\n");
|
||||
printf(" -h shows this text and exits.\n");
|
||||
exit(exitcode);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user