summaryrefslogtreecommitdiff
path: root/src/tools/oping/oping.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/oping/oping.c')
-rw-r--r--src/tools/oping/oping.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/tools/oping/oping.c b/src/tools/oping/oping.c
index 6addbc58..18cc86ee 100644
--- a/src/tools/oping/oping.c
+++ b/src/tools/oping/oping.c
@@ -39,6 +39,7 @@
#define _POSIX_C_SOURCE 199506L
#define __XSI_VISIBLE 500
+#include <ouroboros/endian.h>
#include <ouroboros/fqueue.h>
#include <ouroboros/dev.h>
@@ -70,10 +71,6 @@ struct c {
double rtt_avg;
double rtt_m2;
- /* needs locking */
- struct timespec * times;
- pthread_mutex_t lock;
-
pthread_t reader_pt;
pthread_t writer_pt;
} client;
@@ -92,7 +89,9 @@ struct s {
struct oping_msg {
uint32_t type;
uint32_t id;
-};
+ uint64_t tv_sec;
+ uint64_t tv_nsec;
+} __attribute__((packed));
#include "oping_client.c"
@@ -177,11 +176,6 @@ int main(int argc, char ** argv)
client.size = 64;
}
- if (client.count > 1000000) {
- printf("Count truncated to 1 million SDUs.\n");
- client.count = 1000000;
- }
-
ret = client_main();
}