Copy the null terminator from the string instead of appending it

This commit is contained in:
Chris Robinson
2014-09-30 21:49:29 -07:00
parent d82d6c701d
commit af7330de88
+1 -4
View File
@@ -1266,10 +1266,7 @@ static void AppendDevice(const ALCchar *name, al_string *devnames)
{
size_t len = strlen(name);
if(len > 0)
{
al_string_append_range(devnames, name, name+len);
al_string_append_char(devnames, '\0');
}
al_string_append_range(devnames, name, name+len+1);
}
void AppendAllDevicesList(const ALCchar *name)
{ AppendDevice(name, &alcAllDevicesList); }