* [PATCH] test/pcapng: add some leeway to timestamp test
@ 2026-07-01 22:37 Stephen Hemminger
2026-07-02 21:08 ` Thomas Monjalon
0 siblings, 1 reply; 2+ messages in thread
From: Stephen Hemminger @ 2026-07-01 22:37 UTC (permalink / raw)
To: dev; +Cc: Stephen Hemminger, Reshma Pattan
The timestamp test sometimes fails on busy or emulated CPU's
add additional slop to allow timestamp to be up to 1 second
after capture was stopped.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
app/test/test_pcapng.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/test/test_pcapng.c b/app/test/test_pcapng.c
index 298bcbd31f..d14ea84f0d 100644
--- a/app/test/test_pcapng.c
+++ b/app/test/test_pcapng.c
@@ -440,7 +440,7 @@ valid_pcapng_file(const char *file_name, uint64_t started, unsigned int expected
int ret;
ctx.start_ns = started;
- ctx.end_ns = current_timestamp();
+ ctx.end_ns = current_timestamp() + NS_PER_S;
ctx.pcap = pcap_open_offline_with_tstamp_precision(file_name,
PCAP_TSTAMP_PRECISION_NANO,
--
2.53.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-07-02 21:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-01 22:37 [PATCH] test/pcapng: add some leeway to timestamp test Stephen Hemminger
2026-07-02 21:08 ` Thomas Monjalon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox