diff options
Diffstat (limited to 'Alc/backends/opensl.cpp')
-rw-r--r-- | Alc/backends/opensl.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Alc/backends/opensl.cpp b/Alc/backends/opensl.cpp index e292dfe4..d0b1a7b1 100644 --- a/Alc/backends/opensl.cpp +++ b/Alc/backends/opensl.cpp @@ -375,9 +375,7 @@ static ALCenum ALCopenslPlayback_open(ALCopenslPlayback *self, const ALCchar *na return ALC_INVALID_VALUE; } - al_free(device->DeviceName); - device->DeviceName = alstrdup(name); - + device->DeviceName = name; return ALC_NO_ERROR; } @@ -901,9 +899,7 @@ static ALCenum ALCopenslCapture_open(ALCopenslCapture *self, const ALCchar *name return ALC_INVALID_VALUE; } - al_free(device->DeviceName); - device->DeviceName = alstrdup(name); - + device->DeviceName = name; return ALC_NO_ERROR; } |