Fix compile error with dlerror() on Android

Apparently some dlerror() implementations return the error string as a
const char* in stead of a char* (e.g. Android NDK). Making the variable
storing the returned value a const ensures that it works with any
implementation.

Tested on Linux (GCC) and Android (GCC, API 9, ARM).
This commit is contained in:
Magnus Bjerke Vik 2015-08-05 11:26:44 +02:00
parent 5d082f26fd
commit 3c1cbcfcf1
1 changed files with 1 additions and 1 deletions

View File

@ -186,7 +186,7 @@ namespace cAudio
return ret;
#elif defined(CAUDIO_PLATFORM_MAC) || defined(CAUDIO_PLATFORM_LINUX)
char* error = dlerror();
const char* error = dlerror();
return error != NULL ? cAudioString(error) : cAudioString("");
#else