summaryrefslogtreecommitdiffstats
path: root/src/common
diff options
context:
space:
mode:
authorimarom <imarom@cisco.com>2016-09-05 13:36:07 +0300
committerimarom <imarom@cisco.com>2016-09-07 14:02:58 +0300
commit323238656f07cbb4671e1493d8274ccb532588b1 (patch)
treeea15bf1bfac0582473ec621bb7230b964e048224 /src/common
parent0d4c9932591a46d5e2398dd1049001e107130f44 (diff)
ERF reader missing rewind
Diffstat (limited to 'src/common')
-rwxr-xr-xsrc/common/erf.cpp6
-rwxr-xr-xsrc/common/erf.h2
2 files changed, 8 insertions, 0 deletions
diff --git a/src/common/erf.cpp b/src/common/erf.cpp
index ae256a6b..76945b01 100755
--- a/src/common/erf.cpp
+++ b/src/common/erf.cpp
@@ -437,6 +437,12 @@ void CErfFileReader::Delete(){
}
}
+void CErfFileReader::Rewind() {
+ if (m_handle) {
+ rewind(m_handle);
+ }
+}
+
bool CErfFileReader::ReadPacket(CCapPktRaw * lpPacket){
uint8_t interface;
diff --git a/src/common/erf.h b/src/common/erf.h
index 2feb4fd6..e1b83e46 100755
--- a/src/common/erf.h
+++ b/src/common/erf.h
@@ -247,7 +247,9 @@ public:
virtual ~CErfFileReader() { Delete();}
bool Create(char *filename, int loops = 0);
void Delete();
+
virtual bool ReadPacket(CCapPktRaw * lpPacket);
+ virtual void Rewind();
virtual capture_type_e get_type() {
return ERF;