summaryrefslogtreecommitdiff
path: root/libs
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
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')
-rw-r--r--libs/ardour/ardour/types.h3
-rw-r--r--libs/ardour/audio_playlist_source.cc2
-rw-r--r--libs/ardour/bundle.cc2
-rw-r--r--libs/ardour/butler.cc4
-rw-r--r--libs/ardour/cycle_timer.cc6
-rw-r--r--libs/ardour/delivery.cc6
-rw-r--r--libs/ardour/midi_model.cc26
-rw-r--r--libs/ardour/midi_playlist_source.cc6
-rw-r--r--libs/ardour/panner_shell.cc2
-rw-r--r--libs/ardour/plugin_insert.cc4
-rw-r--r--libs/ardour/region_factory.cc8
-rw-r--r--libs/ardour/send.cc2
-rw-r--r--libs/ardour/session.cc4
-rw-r--r--libs/ardour/session_process.cc2
-rw-r--r--libs/ardour/sndfilesource.cc4
-rw-r--r--libs/ardour/tempo.cc12
-rw-r--r--libs/ardour/track.cc2
-rw-r--r--libs/ardour/utils.cc14
-rw-r--r--libs/evoral/evoral/PatchChange.hpp3
-rw-r--r--libs/evoral/src/ControlList.cpp2
-rw-r--r--libs/evoral/src/Sequence.cpp6
-rw-r--r--libs/gtkmm2ext/actions.cc2
-rw-r--r--libs/gtkmm2ext/gtk_ui.cc2
-rw-r--r--libs/midi++2/mtc.cc2
-rw-r--r--libs/pbd/pool.cc4
25 files changed, 63 insertions, 67 deletions
diff --git a/libs/ardour/ardour/types.h b/libs/ardour/ardour/types.h
index 7444a54a7c..165afd0dd9 100644
--- a/libs/ardour/ardour/types.h
+++ b/libs/ardour/ardour/types.h
@@ -267,8 +267,7 @@ namespace ARDOUR {
return seconds != 0;
}
- /* NOTREACHED */
- assert (false);
+ abort(); /* NOTREACHED */
return false;
}
};
diff --git a/libs/ardour/audio_playlist_source.cc b/libs/ardour/audio_playlist_source.cc
index 5e8dc09d45..5f71d6246f 100644
--- a/libs/ardour/audio_playlist_source.cc
+++ b/libs/ardour/audio_playlist_source.cc
@@ -169,7 +169,7 @@ framecnt_t
AudioPlaylistSource::write_unlocked (Sample *, framecnt_t)
{
fatal << string_compose (_("programming error: %1"), "AudioPlaylistSource::write() called - should be impossible") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0;
}
diff --git a/libs/ardour/bundle.cc b/libs/ardour/bundle.cc
index 834a98d347..7e50807c6e 100644
--- a/libs/ardour/bundle.cc
+++ b/libs/ardour/bundle.cc
@@ -591,7 +591,7 @@ Bundle::type_channel_to_overall (DataType t, uint32_t c) const
++o;
}
- /* NOTREACHED */
+ abort(); /* NOTREACHED */
return -1;
}
diff --git a/libs/ardour/butler.cc b/libs/ardour/butler.cc
index 327665441e..9bc232007b 100644
--- a/libs/ardour/butler.cc
+++ b/libs/ardour/butler.cc
@@ -202,7 +202,7 @@ Butler::dequeue_request (Request::Type& r)
return false;
} else {
fatal << _("Error reading from butler request pipe") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
#else
r = (Request::Type) m_request_state.get();
@@ -242,7 +242,7 @@ Butler::thread_work ()
case Request::Quit:
return 0;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
default:
diff --git a/libs/ardour/cycle_timer.cc b/libs/ardour/cycle_timer.cc
index bb4f3181e0..84dafd00cc 100644
--- a/libs/ardour/cycle_timer.cc
+++ b/libs/ardour/cycle_timer.cc
@@ -38,7 +38,7 @@ get_mhz()
if ((f = fopen("/proc/cpuinfo", "r")) == 0) {
fatal << _("CycleTimer::get_mhz(): can't open /proc/cpuinfo") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0.0f;
}
@@ -50,7 +50,7 @@ get_mhz()
if (fgets (buf, sizeof(buf), f) == 0) {
fatal << _("CycleTimer::get_mhz(): cannot locate cpu MHz in /proc/cpuinfo") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0.0f;
}
@@ -73,7 +73,7 @@ get_mhz()
}
fatal << _("cannot locate cpu MHz in /proc/cpuinfo") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0.0f;
}
diff --git a/libs/ardour/delivery.cc b/libs/ardour/delivery.cc
index 30f7ef63fa..f7d679d3ba 100644
--- a/libs/ardour/delivery.cc
+++ b/libs/ardour/delivery.cc
@@ -148,7 +148,7 @@ Delivery::can_support_io_configuration (const ChanCount& in, ChanCount& out)
}
} else {
fatal << "programming error: this should never be reached" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
@@ -169,7 +169,7 @@ Delivery::can_support_io_configuration (const ChanCount& in, ChanCount& out)
}
} else {
fatal << "programming error: this should never be reached" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
} else {
@@ -210,7 +210,7 @@ Delivery::configure_io (ChanCount in, ChanCount out)
if (_input->n_ports() != in) {
if (_input->n_ports() != ChanCount::ZERO) {
fatal << _name << " programming error: configure_io called with " << in << " and " << out << " with " << _input->n_ports() << " input ports" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
} else {
/* I/O not yet configured */
}
diff --git a/libs/ardour/midi_model.cc b/libs/ardour/midi_model.cc
index ef9544589d..259a04bc0f 100644
--- a/libs/ardour/midi_model.cc
+++ b/libs/ardour/midi_model.cc
@@ -195,11 +195,11 @@ MidiModel::NoteDiffCommand::change (const NotePtr note, Property prop,
case StartTime:
fatal << "MidiModel::DiffCommand::change() with integer argument called for start time" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
case Length:
fatal << "MidiModel::DiffCommand::change() with integer argument called for length" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
}
@@ -627,7 +627,7 @@ MidiModel::NoteDiffCommand::unmarshal_change (XMLNode *xml_change)
change.property = (Property) string_2_enum (prop->value(), change.property);
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if ((prop = xml_change->property ("id")) == 0) {
@@ -648,7 +648,7 @@ MidiModel::NoteDiffCommand::unmarshal_change (XMLNode *xml_change)
}
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if ((prop = xml_change->property ("new")) != 0) {
@@ -662,7 +662,7 @@ MidiModel::NoteDiffCommand::unmarshal_change (XMLNode *xml_change)
}
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
/* we must point at the instance of the note that is actually in the model.
@@ -899,7 +899,7 @@ MidiModel::SysExDiffCommand::unmarshal_change (XMLNode *xml_change)
change.property = (Property) string_2_enum (prop->value(), change.property);
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if ((prop = xml_change->property ("id")) == 0) {
@@ -914,7 +914,7 @@ MidiModel::SysExDiffCommand::unmarshal_change (XMLNode *xml_change)
old_str >> change.old_time;
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
if ((prop = xml_change->property ("new")) != 0) {
@@ -922,7 +922,7 @@ MidiModel::SysExDiffCommand::unmarshal_change (XMLNode *xml_change)
new_str >> change.new_time;
} else {
fatal << "!!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
/* we must point at the instance of the sysex that is actually in the model.
@@ -1728,7 +1728,7 @@ MidiModel::resolve_overlaps_unlocked (const NotePtr note, void* arg)
return -1; /* do not add the new note */
break;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
/* stupid gcc */
break;
}
@@ -1764,7 +1764,7 @@ MidiModel::resolve_overlaps_unlocked (const NotePtr note, void* arg)
note_length = min (note_length, (*i)->end_time() - note->time());
break;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
/* stupid gcc */
break;
}
@@ -1783,7 +1783,7 @@ MidiModel::resolve_overlaps_unlocked (const NotePtr note, void* arg)
/* cannot add in this case */
return -1;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
/* stupid gcc */
break;
}
@@ -1801,14 +1801,14 @@ MidiModel::resolve_overlaps_unlocked (const NotePtr note, void* arg)
to_be_deleted.insert (*i);
break;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
/* stupid gcc */
break;
}
break;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
/* stupid gcc */
break;
}
diff --git a/libs/ardour/midi_playlist_source.cc b/libs/ardour/midi_playlist_source.cc
index 68e0a478df..cd5362c3da 100644
--- a/libs/ardour/midi_playlist_source.cc
+++ b/libs/ardour/midi_playlist_source.cc
@@ -142,7 +142,7 @@ MidiPlaylistSource::write_unlocked (MidiRingBuffer<framepos_t>&,
framecnt_t)
{
fatal << string_compose (_("programming error: %1"), "MidiPlaylistSource::write_unlocked() called - should be impossible") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0;
}
@@ -150,14 +150,14 @@ void
MidiPlaylistSource::append_event_unlocked_beats(const Evoral::Event<Evoral::MusicalTime>& /*ev*/)
{
fatal << string_compose (_("programming error: %1"), "MidiPlaylistSource::append_event_unlocked_beats() called - should be impossible") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
void
MidiPlaylistSource::append_event_unlocked_frames(const Evoral::Event<framepos_t>& /* ev */, framepos_t /*source_start*/)
{
fatal << string_compose (_("programming error: %1"), "MidiPlaylistSource::append_event_unlocked_frames() called - should be impossible") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
void
diff --git a/libs/ardour/panner_shell.cc b/libs/ardour/panner_shell.cc
index a4a9342816..de0780cdba 100644
--- a/libs/ardour/panner_shell.cc
+++ b/libs/ardour/panner_shell.cc
@@ -120,7 +120,7 @@ PannerShell::configure_io (ChanCount in, ChanCount out)
PannerInfo* pi = PannerManager::instance().select_panner (in, out, _user_selected_panner_uri);
if (!pi) {
fatal << _("No panner found: check that panners are being discovered correctly during startup.") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
DEBUG_TRACE (DEBUG::Panning, string_compose (_("select panner: %1\n"), pi->descriptor.name.c_str()));
diff --git a/libs/ardour/plugin_insert.cc b/libs/ardour/plugin_insert.cc
index 26b6aacd2a..0c76b65c84 100644
--- a/libs/ardour/plugin_insert.cc
+++ b/libs/ardour/plugin_insert.cc
@@ -600,7 +600,7 @@ PluginInsert::default_parameter_value (const Evoral::Parameter& param)
if (_plugins.empty()) {
fatal << _("programming error: ") << X_("PluginInsert::default_parameter_value() called with no plugin")
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
return _plugins[0]->default_value (param.id());
@@ -646,7 +646,7 @@ PluginInsert::plugin_factory (boost::shared_ptr<Plugin> other)
fatal << string_compose (_("programming error: %1"),
X_("unknown plugin type in PluginInsert::plugin_factory"))
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return boost::shared_ptr<Plugin> ((Plugin*) 0);
}
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) {
diff --git a/libs/ardour/send.cc b/libs/ardour/send.cc
index 87aadf4193..9d5fd619c3 100644
--- a/libs/ardour/send.cc
+++ b/libs/ardour/send.cc
@@ -65,7 +65,7 @@ Send::name_and_id_new_send (Session& s, Role r, uint32_t& bitslot, bool ignore_b
return string_compose (_("send %1"), (bitslot = s.next_send_id ()) + 1);
default:
fatal << string_compose (_("programming error: send created using role %1"), enum_2_string (r)) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return string();
}
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index 6807bed812..2878bb8014 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -2380,7 +2380,7 @@ Session::new_route_from_template (uint32_t how_many, const std::string& template
/* generate a new name by adding a number to the end of the template name */
if (!find_route_name (route_name.c_str(), ++number, name, sizeof(name), true)) {
fatal << _("Session: UINT_MAX routes? impossible!") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
}
@@ -4041,7 +4041,7 @@ Session::available_capture_duration ()
fatal << string_compose (_("programming error: %1"),
X_("illegal native file data format"))
<< endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
double scale = 4096.0 / sample_bytes_on_disk;
diff --git a/libs/ardour/session_process.cc b/libs/ardour/session_process.cc
index 497fbd4d2e..260c6c319a 100644
--- a/libs/ardour/session_process.cc
+++ b/libs/ardour/session_process.cc
@@ -1169,7 +1169,7 @@ Session::process_event (SessionEvent* ev)
default:
fatal << string_compose(_("Programming error: illegal event type in process_event (%1)"), ev->type) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
};
diff --git a/libs/ardour/sndfilesource.cc b/libs/ardour/sndfilesource.cc
index 58fbab233b..5f1b31c640 100644
--- a/libs/ardour/sndfilesource.cc
+++ b/libs/ardour/sndfilesource.cc
@@ -152,7 +152,7 @@ SndFileSource::SndFileSource (Session& s, const string& path, const string& orig
default:
fatal << string_compose (_("programming error: %1"), X_("unsupported audio header format requested")) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
}
@@ -459,7 +459,7 @@ SndFileSource::nondestructive_write_unlocked (Sample *data, framecnt_t cnt)
if (_info.channels != 1) {
fatal << string_compose (_("programming error: %1 %2"), X_("SndFileSource::write called on non-mono file"), _path) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0;
}
diff --git a/libs/ardour/tempo.cc b/libs/ardour/tempo.cc
index 621d1e2c74..5e50e8e02b 100644
--- a/libs/ardour/tempo.cc
+++ b/libs/ardour/tempo.cc
@@ -677,7 +677,7 @@ TempoMap::first_meter () const
}
fatal << _("programming error: no tempo section in tempo map!") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return *m;
}
@@ -693,7 +693,7 @@ TempoMap::first_tempo () const
}
fatal << _("programming error: no tempo section in tempo map!") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return *t;
}
@@ -807,7 +807,7 @@ TempoMap::recompute_map (bool reassign_tempo_bbt, framepos_t end)
rmeter = ms;
} else {
fatal << _("programming error: unhandled MetricSection type") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
}
}
@@ -1489,8 +1489,7 @@ TempoMap::round_to_type (framepos_t frame, int dir, BBTPointType type)
break;
}
- /* NOTREACHED */
- assert (false);
+ abort(); /* NOTREACHED */
return 0;
}
@@ -1532,6 +1531,7 @@ TempoMap::tempo_section_at (framepos_t frame) const
if (prev == 0) {
fatal << endmsg;
+ abort(); /*NOTREACHED*/
}
return *prev;
@@ -1785,7 +1785,7 @@ TempoMap::insert_time (framepos_t where, framecnt_t amount)
// cerr << "NEW METER, frame = " << (*i)->frame() << " start = " << (*i)->start() <<endl;
} else {
fatal << _("programming error: unhandled MetricSection type") << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
prev = (*i);
diff --git a/libs/ardour/track.cc b/libs/ardour/track.cc
index 03d75d9d79..1426c3926c 100644
--- a/libs/ardour/track.cc
+++ b/libs/ardour/track.cc
@@ -951,7 +951,7 @@ Track::monitoring_state () const
}
}
- /* NOTREACHED */
+ abort(); /* NOTREACHED */
return MonitoringSilence;
}
diff --git a/libs/ardour/utils.cc b/libs/ardour/utils.cc
index 9c0aea885b..6d6511bb9f 100644
--- a/libs/ardour/utils.cc
+++ b/libs/ardour/utils.cc
@@ -429,7 +429,7 @@ ARDOUR::string_to_edit_mode (string str)
return Lock;
}
fatal << string_compose (_("programming error: unknown edit mode string \"%1\""), str) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return Slide;
}
@@ -468,7 +468,7 @@ ARDOUR::string_to_sync_source (string str)
}
fatal << string_compose (_("programming error: unknown sync source string \"%1\""), str) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return Engine;
}
@@ -577,7 +577,7 @@ ARDOUR::string_to_auto_state (std::string str)
}
fatal << string_compose (_("programming error: %1 %2"), "illegal AutoState string: ", str) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return Touch;
}
@@ -601,7 +601,7 @@ ARDOUR::auto_state_to_string (AutoState as)
}
fatal << string_compose (_("programming error: %1 %2"), "illegal AutoState type: ", as) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return "";
}
@@ -615,7 +615,7 @@ ARDOUR::string_to_auto_style (std::string str)
}
fatal << string_compose (_("programming error: %1 %2"), "illegal AutoStyle string: ", str) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return Trim;
}
@@ -634,7 +634,7 @@ ARDOUR::auto_style_to_string (AutoStyle as)
}
fatal << string_compose (_("programming error: %1 %2"), "illegal AutoStyle type: ", as) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return "";
}
@@ -669,7 +669,7 @@ ARDOUR::native_header_format_extension (HeaderFormat hf, const DataType& type)
}
fatal << string_compose (_("programming error: unknown native header format: %1"), hf);
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return ".wav";
}
diff --git a/libs/evoral/evoral/PatchChange.hpp b/libs/evoral/evoral/PatchChange.hpp
index e05157aa92..48ed0f9c13 100644
--- a/libs/evoral/evoral/PatchChange.hpp
+++ b/libs/evoral/evoral/PatchChange.hpp
@@ -147,8 +147,7 @@ public:
case 2:
return _program_change;
default:
- abort ();
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return _program_change;
}
}
diff --git a/libs/evoral/src/ControlList.cpp b/libs/evoral/src/ControlList.cpp
index 3f70cde274..deabd9d1cc 100644
--- a/libs/evoral/src/ControlList.cpp
+++ b/libs/evoral/src/ControlList.cpp
@@ -1199,7 +1199,7 @@ ControlList::unlocked_eval (double x) const
return multipoint_eval (x);
}
- /*NOTREACHED*/ /* stupid gcc */
+ abort(); /*NOTREACHED*/ /* stupid gcc */
return _default_value;
}
diff --git a/libs/evoral/src/Sequence.cpp b/libs/evoral/src/Sequence.cpp
index 4487bc43c4..1cc8ff6e0f 100644
--- a/libs/evoral/src/Sequence.cpp
+++ b/libs/evoral/src/Sequence.cpp
@@ -1346,8 +1346,7 @@ Sequence<Time>::get_notes_by_pitch (Notes& n, NoteOperator op, uint8_t val, int
default:
//fatal << string_compose (_("programming error: %1 %2", X_("get_notes_by_pitch() called with illegal operator"), op)) << endmsg;
- abort ();
- /* NOTREACHED*/
+ abort(); /* NOTREACHED*/
}
}
}
@@ -1392,8 +1391,7 @@ Sequence<Time>::get_notes_by_velocity (Notes& n, NoteOperator op, uint8_t val, i
break;
default:
// fatal << string_compose (_("programming error: %1 %2", X_("get_notes_by_velocity() called with illegal operator"), op)) << endmsg;
- abort ();
- /* NOTREACHED*/
+ abort(); /* NOTREACHED*/
}
}
diff --git a/libs/gtkmm2ext/actions.cc b/libs/gtkmm2ext/actions.cc
index 5f853b0170..666ac29c5c 100644
--- a/libs/gtkmm2ext/actions.cc
+++ b/libs/gtkmm2ext/actions.cc
@@ -490,7 +490,7 @@ ActionManager::set_toggleaction_state (string n, bool s)
if (last_slash == 0) {
fatal << string_compose ("programmer error: %1 %2", "illegal toggle action name", name) << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return;
}
diff --git a/libs/gtkmm2ext/gtk_ui.cc b/libs/gtkmm2ext/gtk_ui.cc
index 6a490e1bb0..df7ec96324 100644
--- a/libs/gtkmm2ext/gtk_ui.cc
+++ b/libs/gtkmm2ext/gtk_ui.cc
@@ -81,7 +81,7 @@ UI::UI (string namestr, int *argc, char ***argv)
theGtkUI = this;
} else {
fatal << "duplicate UI requested" << endmsg;
- /* NOTREACHED */
+ abort(); /* NOTREACHED */
}
/* the GUI event loop runs in the main thread of the app,
diff --git a/libs/midi++2/mtc.cc b/libs/midi++2/mtc.cc
index 1a477c3b8c..e2a018ca51 100644
--- a/libs/midi++2/mtc.cc
+++ b/libs/midi++2/mtc.cc
@@ -285,7 +285,7 @@ Parser::process_mtc_quarter_frame (MIDI::byte *msg)
break;
default:
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
break;
}
diff --git a/libs/pbd/pool.cc b/libs/pbd/pool.cc
index cdcd9abdd7..234dfaeb18 100644
--- a/libs/pbd/pool.cc
+++ b/libs/pbd/pool.cc
@@ -70,7 +70,7 @@ Pool::alloc ()
if (free_list.read (&ptr, 1) < 1) {
fatal << "CRITICAL: " << _name << " POOL OUT OF MEMORY - RECOMPILE WITH LARGER SIZE!!" << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
return 0;
} else {
return ptr;
@@ -184,7 +184,7 @@ PerThreadPool::per_thread_pool ()
CrossThreadPool* p = _key.get();
if (!p) {
fatal << "programming error: no per-thread pool \"" << _name << "\" for thread " << pthread_name() << endmsg;
- /*NOTREACHED*/
+ abort(); /*NOTREACHED*/
}
return p;
}