summaryrefslogtreecommitdiff
path: root/libs/ardour/region_factory.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2014-11-14 10:47:43 +0100
committerRobin Gareus <robin@gareus.org>2014-11-14 11:30:08 +0100
commit6b3a8915f3c50f7220121fcb9202ec20144389c4 (patch)
tree08e7ae373859e5ca15b8fa0ca075b18b65915a22 /libs/ardour/region_factory.cc
parent5d5d9cb9e262498dc0831dc362fbcb3f92bcdb9f (diff)
add abort() to non-reached code
This cleans up a lot of false-positives in static analysis and also helps compilers to optimize code paths in general. (tagging the fatal stingstream operator as ‘noreturn’ is far less trivial)
Diffstat (limited to 'libs/ardour/region_factory.cc')
-rw-r--r--libs/ardour/region_factory.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/libs/ardour/region_factory.cc b/libs/ardour/region_factory.cc
index 44f8c34ddd..9654a4b3de 100644
--- a/libs/ardour/region_factory.cc
+++ b/libs/ardour/region_factory.cc
@@ -66,7 +66,7 @@ RegionFactory::create (boost::shared_ptr<const Region> region, bool announce)
} else {
fatal << _("programming error: RegionFactory::create() called with unknown Region type")
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if (ret) {
@@ -108,7 +108,7 @@ RegionFactory::create (boost::shared_ptr<Region> region, const PropertyList& pli
} else {
fatal << _("programming error: RegionFactory::create() called with unknown Region type")
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return boost::shared_ptr<Region>();
}
@@ -149,7 +149,7 @@ RegionFactory::create (boost::shared_ptr<Region> region, frameoffset_t offset, c
} else {
fatal << _("programming error: RegionFactory::create() called with unknown Region type")
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return boost::shared_ptr<Region>();
}
@@ -191,7 +191,7 @@ RegionFactory::create (boost::shared_ptr<Region> region, const SourceList& srcs,
} else {
fatal << _("programming error: RegionFactory::create() called with unknown Region type")
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if (ret) {