diff options
author | Max Kellermann <max@musicpd.org> | 2017-05-08 14:44:49 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-05-08 14:44:49 +0200 |
commit | 71f0ed8b7499011b53f90998ebfbd3250fd80948 (patch) | |
tree | e9c2f66fbef231858f46d878864199d46e6ce21c /src/output/plugins/JackOutputPlugin.cxx | |
parent | ac2e4e593d407e41db49fdb9ae2da6bc1557f618 (diff) |
*: add "noexcept" to many, many function prototypes
This eliminates some overhead, because the compiler doesn't need to
consider these functions throwing.
Diffstat (limited to 'src/output/plugins/JackOutputPlugin.cxx')
-rw-r--r-- | src/output/plugins/JackOutputPlugin.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/output/plugins/JackOutputPlugin.cxx b/src/output/plugins/JackOutputPlugin.cxx index 0ad5768d3..11a186fb7 100644 --- a/src/output/plugins/JackOutputPlugin.cxx +++ b/src/output/plugins/JackOutputPlugin.cxx @@ -119,7 +119,7 @@ struct JackOutput { * on all channels. */ gcc_pure - jack_nframes_t GetAvailable() const; + jack_nframes_t GetAvailable() const noexcept; void Process(jack_nframes_t nframes); @@ -128,7 +128,7 @@ struct JackOutput { */ size_t WriteSamples(const float *src, size_t n_frames); - std::chrono::steady_clock::duration Delay() const { + std::chrono::steady_clock::duration Delay() const noexcept { return base.pause && pause && !shutdown ? std::chrono::seconds(1) : std::chrono::steady_clock::duration::zero(); @@ -215,7 +215,7 @@ JackOutput::JackOutput(const ConfigBlock &block) } inline jack_nframes_t -JackOutput::GetAvailable() const +JackOutput::GetAvailable() const noexcept { size_t min = jack_ringbuffer_read_space(ringbuffer[0]); |