From 7ba80ed4aa8e23e0a8b97f59341642dc2b7b76e9 Mon Sep 17 00:00:00 2001 From: gwm17 Date: Wed, 22 Jun 2022 15:33:49 -0400 Subject: [PATCH] Fix bug with zero file size edge case now needing to be file contains only header case --- .gitignore | 6 ++---- src/evb/CompassFile.cpp | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 529300c..311cbc7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,6 @@ ###directories to ignore### -./rootfiles/ -./pics/ -./images/ -./hotfixes/ +.vscode/ +build/ ###file types to ignore### *.swp diff --git a/src/evb/CompassFile.cpp b/src/evb/CompassFile.cpp index f6c9e0f..622682e 100644 --- a/src/evb/CompassFile.cpp +++ b/src/evb/CompassFile.cpp @@ -47,7 +47,7 @@ namespace EventBuilder { m_file->seekg(0, std::ios_base::end); m_size = m_file->tellg(); - if(m_size == 0) + if(m_size == 2) { m_eofFlag = true; }