Skip to content

Commit 651294c

Browse files
committed
fix: use same default value as rust example
1 parent 57c4845 commit 651294c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

examples/unix/c11/z_ping.c

+4-4
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ int main(int argc, char** argv) {
5050
if (args.help_requested) {
5151
printf(
5252
"\
53-
-n (optional, int, default=4): the number of pings to be attempted\n\
53+
-n (optional, int, default=100): the number of pings to be attempted\n\
5454
-s (optional, int, default=8): the size of the payload embedded in the ping and repeated by the pong\n\
55-
-w (optional, int, default=0): the warmup time in ms during which pings will be emitted but not measured\n\
55+
-w (optional, int, default=1000): the warmup time in ms during which pings will be emitted but not measured\n\
5656
-c (optional, string): the path to a configuration file for the session. If this option isn't passed, the default configuration will be used.\n\
5757
");
5858
return 1;
@@ -150,12 +150,12 @@ struct args_t parse_args(int argc, char** argv) {
150150
size = atoi(arg);
151151
}
152152
arg = getopt(argc, argv, 'n');
153-
unsigned int number_of_pings = 4;
153+
unsigned int number_of_pings = 100;
154154
if (arg) {
155155
number_of_pings = atoi(arg);
156156
}
157157
arg = getopt(argc, argv, 'w');
158-
unsigned int warmup_ms = 0;
158+
unsigned int warmup_ms = 1000;
159159
if (arg) {
160160
warmup_ms = atoi(arg);
161161
}

0 commit comments

Comments
 (0)