Commit f3960b22 authored by Alexandre Julliard's avatar Alexandre Julliard

libwine: Hack to work around the Solaris dlopen() brain damage.

parent c4ad5eeb
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <assert.h> #include <assert.h>
#include <ctype.h> #include <ctype.h>
#include <fcntl.h> #include <fcntl.h>
#include <limits.h>
#include <stdarg.h> #include <stdarg.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
...@@ -689,6 +690,16 @@ void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize ...@@ -689,6 +690,16 @@ void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize
void *ret; void *ret;
const char *s; const char *s;
dlerror(); dlerror(); dlerror(); dlerror();
#ifdef __sun
if (strchr( filename, ':' ))
{
char path[PATH_MAX];
/* Solaris' brain damaged dlopen() treats ':' as a path separator */
realpath( filename, path );
ret = dlopen( path, flag | RTLD_FIRST );
}
else
#endif
ret = dlopen( filename, flag | RTLD_FIRST ); ret = dlopen( filename, flag | RTLD_FIRST );
s = dlerror(); s = dlerror();
if (error && errorsize) if (error && errorsize)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment