diff options
Diffstat (limited to 'src/tools')
-rw-r--r-- | src/tools/oping/oping.c | 9 | ||||
-rw-r--r-- | src/tools/oping/oping_server.c | 2 |
2 files changed, 7 insertions, 4 deletions
diff --git a/src/tools/oping/oping.c b/src/tools/oping/oping.c index e3e9116f..bc8907e6 100644 --- a/src/tools/oping/oping.c +++ b/src/tools/oping/oping.c @@ -123,7 +123,8 @@ static void usage(void) " -d, --duration Duration of the test (default 1s)\n" " -i, --interval Interval (default 1000ms)\n" " -n, --server-name Name of the oping server\n" - " -q, --qos QoS (raw, best, video or voice)\n" + " -q, --qos QoS (raw, best, video, voice, data)" + "\n" " -s, --size Payload size (B, default 64)\n" " -Q, --quiet Only print final statistics\n" " -D, --timeofday Print time of day before each line" @@ -145,10 +146,10 @@ static int time_mul(const char * rem) else if (strcmp(rem, "d") == 0) return 60 * 60 * 24 * 1000; - printf("Unknown time unit: %s.", rem); + printf("Unknown time unit: %s.\n", rem); usage(); - exit(EXIT_SUCCESS); + exit(EXIT_FAILURE); } int main(int argc, @@ -231,6 +232,8 @@ int main(int argc, client.qs = qos_video; else if (strcmp(qos, "voice") == 0) client.qs = qos_voice; + else if (strcmp(qos, "data") == 0) + client.qs = qos_data; else printf("Unknown QoS cube, defaulting to raw.\n"); } diff --git a/src/tools/oping/oping_server.c b/src/tools/oping/oping_server.c index 10926763..152aa512 100644 --- a/src/tools/oping/oping_server.c +++ b/src/tools/oping/oping_server.c @@ -96,7 +96,7 @@ void * server_thread(void *o) continue; if (ntohl(msg->type) != ECHO_REQUEST) { - printf("Invalid message on fd %d.", fd); + printf("Invalid message on fd %d.\n", fd); continue; } |