diff options
author | Chris Robinson <[email protected]> | 2018-11-15 06:23:01 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-11-15 06:23:01 -0800 |
commit | 7b3a2085aac8eac47f9968f331d3991167793e85 (patch) | |
tree | 5566b15f7a90fe8e0fb2b280c4f8b83c80247f4f /Alc/backends/sdl2.cpp | |
parent | ab9f8162b84870161948ddd27d29483206dd4e57 (diff) |
Use a regular char* for the device's name
Diffstat (limited to 'Alc/backends/sdl2.cpp')
-rw-r--r-- | Alc/backends/sdl2.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Alc/backends/sdl2.cpp b/Alc/backends/sdl2.cpp index 82c350e1..c918b57c 100644 --- a/Alc/backends/sdl2.cpp +++ b/Alc/backends/sdl2.cpp @@ -174,7 +174,8 @@ static ALCenum ALCsdl2Backend_open(ALCsdl2Backend *self, const ALCchar *name) self->FmtType = device->FmtType; self->UpdateSize = device->UpdateSize; - alstr_copy_cstr(&device->DeviceName, name ? name : defaultDeviceName); + al_free(device->DeviceName); + device->DeviceName = alstrdup(name ? name : defaultDeviceName); return ALC_NO_ERROR; } |