From 245d762ed1d59c409c4f8793b509c3c3a89208ac Mon Sep 17 00:00:00 2001
From: Pierre LALET <pierre.lalet@cea.fr>
Date: Sat, 30 Jan 2016 15:02:22 +0100
Subject: [PATCH] pcapng support: fix after review by @guedou

---
 scapy/utils.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scapy/utils.py b/scapy/utils.py
index 0a503999..584a7c20 100644
--- a/scapy/utils.py
+++ b/scapy/utils.py
@@ -533,7 +533,7 @@ count: read only <count> packets"""
         return fdesc.read_all(count=count)
 
 def rdpcapng(filename, count=-1):
-    """Read a pcap file and return a packet list
+    """Read a pcapng file and return a packet list
 count: read only <count> packets"""
     ## Does not work with Python <= 2.5. Use this implementation as
     ## soon as we drop support for Python 2.5.
@@ -688,7 +688,7 @@ class RawPcapNgReader(RawPcapReader):
         except IOError:
             self.f = open(filename,"rb")
             magic = self.f.read(4)
-        if magic != "\n\r\r\n": # PcapNg:
+        if magic != "\x0a\x0d\x0d\x0a": # PcapNg:
             raise Scapy_Exception(
                 "Not a pcapng capture file (bad magic: %r)" % magic
             )
-- 
GitLab