summaryrefslogtreecommitdiffstats
path: root/Alc/portaudio.c
diff options
context:
space:
mode:
Diffstat (limited to 'Alc/portaudio.c')
-rw-r--r--Alc/portaudio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/portaudio.c b/Alc/portaudio.c
index fb4b8ed5..7ef255f2 100644
--- a/Alc/portaudio.c
+++ b/Alc/portaudio.c
@@ -199,7 +199,7 @@ void alc_pa_init(BackendFuncs *func_list)
const char *str;
PaError err;
- *func_list = pa_funcs;
+ if(func_list) *func_list = pa_funcs;
#ifdef HAVE_DLFCN_H
#if defined(__APPLE__) && defined(__MACH__)
@@ -261,8 +261,8 @@ void alc_pa_deinit(void)
void alc_pa_probe(int type)
{
- if(!pa_handle)
- return;
+ if(!pa_handle) alc_pa_init(NULL);
+ if(!pa_handle) return;
if(type == DEVICE_PROBE)
AppendDeviceList(pa_device);