From 0812c0585a99df5eeb516c1b0490c9afa04f796b Mon Sep 17 00:00:00 2001
From: gpotter2 <gabriel@potter.fr>
Date: Wed, 30 Aug 2017 12:39:20 +0200
Subject: [PATCH] Fix decimal timestamp on Windows

---
 scapy/arch/pcapdnet.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scapy/arch/pcapdnet.py b/scapy/arch/pcapdnet.py
index 06a67a9c..9193a8a4 100644
--- a/scapy/arch/pcapdnet.py
+++ b/scapy/arch/pcapdnet.py
@@ -149,7 +149,7 @@ if conf.use_winpcapy:
           c = pcap_next_ex(self.pcap, byref(self.header), byref(self.pkt_data))
           if not c > 0:
               return
-          ts = self.header.contents.ts.tv_sec
+          ts = self.header.contents.ts.tv_sec + float(self.header.contents.ts.tv_usec) / 1000000
           pkt = "".join(chr(i) for i in self.pkt_data[:self.header.contents.len])
           return ts, pkt
       __next__ = next
-- 
GitLab