From cdadbe8bcceb8230c46a3c6f836e98fafa4cb749 Mon Sep 17 00:00:00 2001 From: Dennis Potter Date: Thu, 2 Aug 2018 16:25:07 +0200 Subject: [PATCH] Changed precision of offset to nanoseconds for csv. Fixes #189 --- lib/formats/csv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/formats/csv.c b/lib/formats/csv.c index 93891cf5e..3e5eca362 100644 --- a/lib/formats/csv.c +++ b/lib/formats/csv.c @@ -41,7 +41,7 @@ static size_t csv_sprint_single(struct io *io, char *buf, size_t len, struct sam off += snprintf(buf + off, len - off, "nan%cnan", io->separator); if (io->flags & SAMPLE_HAS_RECEIVED) - off += snprintf(buf + off, len - off, "%c%f", io->separator, time_delta(&s->ts.origin, &s->ts.received)); + off += snprintf(buf + off, len - off, "%c%.09f", io->separator, time_delta(&s->ts.origin, &s->ts.received)); else off += snprintf(buf + off, len - off, "%cnan", io->separator);