* src/vm/os.hpp (os::dlerror): Cast return value to char*.
authorChristian Thalinger <twisti@complang.tuwien.ac.at>
Thu, 18 Sep 2008 13:00:07 +0000 (15:00 +0200)
committerChristian Thalinger <twisti@complang.tuwien.ac.at>
Thu, 18 Sep 2008 13:00:07 +0000 (15:00 +0200)
src/vm/os.hpp

index 82f8c4811864fab25c974971025b70a3ecc2d16e..66de93d5155630e879a91ecd66cb3e81a2b945bb 100644 (file)
@@ -275,7 +275,9 @@ inline int os::dlclose(void* handle)
 inline char* os::dlerror(void)
 {
 #if defined(HAVE_DLERROR)
-       return ::dlerror();
+       // At least FreeBSD defines dlerror() to return a const char*, so
+       // we simply cast it.
+       return (char*) ::dlerror();
 #else
 # error dlerror not available
 #endif