Bugzilla bug #66325: use the DYNAMIC_PATH flag for shl_load() only if the
specified path name is a plain file name (containing no directory), to match the behavior of dlopen(). git-svn-id: svn://10.0.0.236/trunk@85377 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -755,9 +755,17 @@ pr_LoadLibraryByPathname(const char *name, PRIntn flags)
|
||||
}
|
||||
h = dlopen(name, dl_flags);
|
||||
#elif defined(USE_HPSHL)
|
||||
int shl_flags = DYNAMIC_PATH;
|
||||
int shl_flags = 0;
|
||||
shl_t h;
|
||||
|
||||
/*
|
||||
* Use the DYNAMIC_PATH flag only if 'name' is a plain file
|
||||
* name (containing no directory) to match the behavior of
|
||||
* dlopen().
|
||||
*/
|
||||
if (strchr(name, PR_DIRECTORY_SEPARATOR) == NULL) {
|
||||
shl_flags |= DYNAMIC_PATH;
|
||||
}
|
||||
if (flags & PR_LD_LAZY) {
|
||||
shl_flags |= BIND_DEFERRED;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user