diff options
Diffstat (limited to 'Alc/backends/sndio.cpp')
-rw-r--r-- | Alc/backends/sndio.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Alc/backends/sndio.cpp b/Alc/backends/sndio.cpp index c97226a6..f1e678cf 100644 --- a/Alc/backends/sndio.cpp +++ b/Alc/backends/sndio.cpp @@ -148,7 +148,8 @@ static ALCenum SndioPlayback_open(SndioPlayback *self, const ALCchar *name) return ALC_INVALID_VALUE; } - alstr_copy_cstr(&device->DeviceName, name); + al_free(device->DeviceName); + device->DeviceName = alstrdup(name); return ALC_NO_ERROR; } @@ -488,7 +489,8 @@ static ALCenum SndioCapture_open(SndioCapture *self, const ALCchar *name) SetDefaultChannelOrder(device); - alstr_copy_cstr(&device->DeviceName, name); + al_free(device->DeviceName); + device->DeviceName = alstrdup(name); return ALC_NO_ERROR; } |