diff options
author | Chris Robinson <[email protected]> | 2018-11-13 18:05:10 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-11-13 18:41:24 -0800 |
commit | 7088f4e34a8557f2c73ee6635b3c7bf4ec958c63 (patch) | |
tree | 48fcff3de36d357a0cdbd97840a93e9bdd3be30e /Alc/backends/qsa.cpp | |
parent | 0dfb805fa2f85bed47612a75628d7d9742877b26 (diff) |
Avoid calling through the vtable in the backends
Diffstat (limited to 'Alc/backends/qsa.cpp')
-rw-r--r-- | Alc/backends/qsa.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Alc/backends/qsa.cpp b/Alc/backends/qsa.cpp index 778e9e44..b2890705 100644 --- a/Alc/backends/qsa.cpp +++ b/Alc/backends/qsa.cpp @@ -188,7 +188,7 @@ DEFINE_ALCBACKEND_VTABLE(PlaybackWrapper); FORCE_ALIGN static int qsa_proc_playback(void *ptr) { - PlaybackWrapper *self = ptr; + PlaybackWrapper *self = static_cast<PlaybackWrapper*>(ptr); ALCdevice *device = STATIC_CAST(ALCbackend,self)->mDevice; qsa_data *data = self->ExtraData; snd_pcm_channel_status_t status; @@ -211,7 +211,7 @@ FORCE_ALIGN static int qsa_proc_playback(void *ptr) device->FmtChans, device->FmtType, device->AmbiOrder ); - V0(device->Backend,lock)(); + PlaybackWrapper_lock(self); while(!ATOMIC_LOAD(&data->killNow, almemory_order_acquire)) { FD_ZERO(&wfds); @@ -220,9 +220,9 @@ FORCE_ALIGN static int qsa_proc_playback(void *ptr) timeout.tv_usec=0; /* Select also works like time slice to OS */ - V0(device->Backend,unlock)(); + PlaybackWrapper_unlock(self); sret = select(data->audio_fd+1, NULL, &wfds, NULL, &timeout); - V0(device->Backend,lock)(); + PlaybackWrapper_lock(self); if(sret == -1) { ERR("select error: %s\n", strerror(errno)); @@ -269,7 +269,7 @@ FORCE_ALIGN static int qsa_proc_playback(void *ptr) } } } - V0(device->Backend,unlock)(); + PlaybackWrapper_unlock(self); return 0; } |