aboutsummaryrefslogtreecommitdiffstats
path: root/alc/backends/opensl.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2019-10-09 03:29:25 -0700
committerChris Robinson <[email protected]>2019-10-09 03:29:25 -0700
commitb687e952efa7407e323e8465df41e2e84b277b31 (patch)
treeaa2272b383366a2c37c9663e498ea1bc158a8984 /alc/backends/opensl.cpp
parenta7c12453600d4e9ae756b933770c6f42977a2663 (diff)
Make C callbacks noexcept
No telling what would happen if exceptions managed to get back into presumably C-based callers.
Diffstat (limited to 'alc/backends/opensl.cpp')
-rw-r--r--alc/backends/opensl.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/alc/backends/opensl.cpp b/alc/backends/opensl.cpp
index 258443f2..4bba3455 100644
--- a/alc/backends/opensl.cpp
+++ b/alc/backends/opensl.cpp
@@ -146,8 +146,8 @@ struct OpenSLPlayback final : public BackendBase {
OpenSLPlayback(ALCdevice *device) noexcept : BackendBase{device} { }
~OpenSLPlayback() override;
- void process(SLAndroidSimpleBufferQueueItf bq);
- static void processC(SLAndroidSimpleBufferQueueItf bq, void *context)
+ void process(SLAndroidSimpleBufferQueueItf bq) noexcept;
+ static void processC(SLAndroidSimpleBufferQueueItf bq, void *context) noexcept
{ static_cast<OpenSLPlayback*>(context)->process(bq); }
int mixerProc();
@@ -197,7 +197,7 @@ OpenSLPlayback::~OpenSLPlayback()
/* this callback handler is called every time a buffer finishes playing */
-void OpenSLPlayback::process(SLAndroidSimpleBufferQueueItf)
+void OpenSLPlayback::process(SLAndroidSimpleBufferQueueItf) noexcept
{
/* A note on the ringbuffer usage: The buffer queue seems to hold on to the
* pointer passed to the Enqueue method, rather than copying the audio.
@@ -622,8 +622,8 @@ struct OpenSLCapture final : public BackendBase {
OpenSLCapture(ALCdevice *device) noexcept : BackendBase{device} { }
~OpenSLCapture() override;
- void process(SLAndroidSimpleBufferQueueItf bq);
- static void processC(SLAndroidSimpleBufferQueueItf bq, void *context)
+ void process(SLAndroidSimpleBufferQueueItf bq) noexcept;
+ static void processC(SLAndroidSimpleBufferQueueItf bq, void *context) noexcept
{ static_cast<OpenSLCapture*>(context)->process(bq); }
void open(const ALCchar *name) override;
@@ -660,7 +660,7 @@ OpenSLCapture::~OpenSLCapture()
}
-void OpenSLCapture::process(SLAndroidSimpleBufferQueueItf)
+void OpenSLCapture::process(SLAndroidSimpleBufferQueueItf) noexcept
{
/* A new chunk has been written into the ring buffer, advance it. */
mRing->writeAdvance(1);