[rtems-tools commit] covoar: Catch exceptional case
Joel Sherrill
joel at rtems.org
Tue Mar 30 18:20:47 UTC 2021
Module: rtems-tools
Branch: master
Commit: 9720218673da737d68dab5ba8903bee28abd5e25
Changeset: http://git.rtems.org/rtems-tools/commit/?id=9720218673da737d68dab5ba8903bee28abd5e25
Author: Alex White <alex.white at oarcorp.com>
Date: Thu Feb 25 11:08:36 2021 -0600
covoar: Catch exceptional case
---
tester/covoar/ExecutableInfo.cc | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/tester/covoar/ExecutableInfo.cc b/tester/covoar/ExecutableInfo.cc
index 2fcacf2..b75d0b5 100644
--- a/tester/covoar/ExecutableInfo.cc
+++ b/tester/covoar/ExecutableInfo.cc
@@ -167,6 +167,16 @@ namespace Coverage {
CoverageMapBase *theMap;
CoverageMaps::iterator itr;
+ if ( lowAddress > highAddress ) {
+ std::ostringstream what;
+ what << "Low address is greater than high address for symbol "
+ << symbolName
+ << " (" << lowAddress
+ << " and " << highAddress
+ << ")";
+ throw rld::error( what, "ExecutableInfo::createCoverageMap" );
+ }
+
itr = coverageMaps.find( symbolName );
if ( itr == coverageMaps.end() ) {
theMap = new CoverageMap( fileName, lowAddress, highAddress );
More information about the vc
mailing list