add: help message

This commit is contained in:
2025-12-16 08:35:26 -06:00
parent bed729e8e1
commit 4466ac1c60
4 changed files with 31 additions and 2 deletions

View File

@@ -93,7 +93,11 @@ int main(int ac, char **av)
struct statistics stats;
struct setting settings;
if (get_setting(av + 1, &settings))
int ret = get_setting(av + 1, &settings);
if (ret == -1)
goto finish;
if (ret)
goto error0;
size_t packet_size = sizeof(struct icmphdr) + settings.payload_size;
@@ -168,6 +172,7 @@ int main(int ac, char **av)
print_statistics(&stats, &settings);
finish:
return 0;
error3: