diff options
author | Chris Robinson <[email protected]> | 2009-08-27 02:53:09 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2009-08-27 02:53:09 -0700 |
commit | 6bb14e45cee9d8d7da37675cc6933146f7a95155 (patch) | |
tree | 238b8354671a87e00867af28424a4bf23b813e1c /Alc/solaris.c | |
parent | 45dc8048193162edbb886921cfcf2955c5232626 (diff) |
Store a copy of the device name in the device
Diffstat (limited to 'Alc/solaris.c')
-rw-r--r-- | Alc/solaris.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/solaris.c b/Alc/solaris.c index 5c7716f6..63f92bf4 100644 --- a/Alc/solaris.c +++ b/Alc/solaris.c @@ -92,6 +92,7 @@ static ALuint SolarisProc(ALvoid *ptr) static ALCboolean solaris_open_playback(ALCdevice *device, const ALCchar *deviceName) { + const char *devName = solaris_device; audio_info_t info; ALuint frameSize; char driver[64]; @@ -104,10 +105,8 @@ static ALCboolean solaris_open_playback(ALCdevice *device, const ALCchar *device { if(strcmp(deviceName, solaris_device)) return ALC_FALSE; - device->szDeviceName = solaris_device; + devName = solaris_device; } - else - device->szDeviceName = solaris_device; data = (solaris_data*)calloc(1, sizeof(solaris_data)); data->killNow = 0; @@ -194,6 +193,7 @@ static ALCboolean solaris_open_playback(ALCdevice *device, const ALCchar *device return ALC_FALSE; } + device->szDeviceName = strdup(devName); return ALC_TRUE; } |