From 6b3aac87fe4456b49746ec528601ef9d518e08a6 Mon Sep 17 00:00:00 2001 From: Mario Fink Date: Wed, 29 Jul 2020 15:33:53 +0200 Subject: [PATCH] show found markers, hex::show: include last incomplete line --- lib/hexshow.hpp | 8 ++++++-- lib/raweat.hpp | 19 +++++++++++++++++++ makefile | 2 +- src/main.cpp | 2 +- 4 files changed, 27 insertions(+), 4 deletions(-) diff --git a/lib/hexshow.hpp b/lib/hexshow.hpp index 7489e55..3fcbd33 100644 --- a/lib/hexshow.hpp +++ b/lib/hexshow.hpp @@ -43,9 +43,13 @@ namespace hex unsigned char elcl = ( (int)el > 0x1f && (int)el < 0x7f) ? el : '.'; sschr<> mrk : markers_ ) + { + // extract data of marker + std::vector mrkdat = this->datasec_[mrk.first]; + + // show name of marker and its data + std::cout<> get_markers() { diff --git a/makefile b/makefile index d66f868..c309fc8 100644 --- a/makefile +++ b/makefile @@ -11,7 +11,7 @@ CCC = g++ -std=c++11 OPT = -O3 -Wall -mavx -mno-tbm -mf16c -mno-f16c # build executable -$(EXE) : $(SRC)main.cpp $(LIB)raweat.hpp +$(EXE) : $(SRC)main.cpp $(LIB)raweat.hpp $(LIB)hexshow.hpp $(CCC) $(OPT) $< -o $@ eatdev : $(SRC)main_dev.cpp $(LIB)raweat.hpp diff --git a/src/main.cpp b/src/main.cpp index efc76f7..d4d708c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -29,7 +29,7 @@ int main(int argc, char* argv[]) std::string rawfile(argv[1]); // declare instance of "raw_eater" - raw_eater eatraw(rawfile); + raw_eater eatraw(rawfile,true); //eatraw.show_markers();