mirror of
git://git.savannah.gnu.org/libtool.git
synced 2025-01-12 14:06:37 +08:00
* libltdl/ltdl.c (try_dlopen): Fix null pointer dereference in
case the name given to lt_dlopen contains no extension.
This commit is contained in:
parent
8286085803
commit
228e9808f8
@ -1,5 +1,8 @@
|
||||
2004-09-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
|
||||
|
||||
* libltdl/ltdl.c (try_dlopen): Fix null pointer dereference in
|
||||
case the name given to lt_dlopen contains no extension.
|
||||
|
||||
* libltdl/lt_dlloader.c (lt_dlloader_remove), libltdl/ltdl.c
|
||||
(tryall_dlopen, lt_dlhandle_next): Show usage of function pointers.
|
||||
|
||||
|
@ -986,6 +986,10 @@ try_dlopen (lt_dlhandle *phandle, const char *filename)
|
||||
assert (base_name && *base_name);
|
||||
|
||||
ext = strrchr (base_name, '.');
|
||||
if (!ext)
|
||||
{
|
||||
ext = base_name + LT_STRLEN (base_name);
|
||||
}
|
||||
|
||||
/* extract the module name from the file name */
|
||||
name = MALLOC (char, ext - base_name + 1);
|
||||
|
Loading…
Reference in New Issue
Block a user