mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-14 10:09:48 +00:00
extlen and cpp is not used here in linker_search_kld(), so nuke them.
Reported by: Mingyan Guo <guomingyan at gmail dot com> MFC After: 2 weeks
This commit is contained in:
parent
84c929db19
commit
e38c7f3ef3
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=158972
@ -1644,21 +1644,13 @@ linker_search_module(const char *modname, int modnamelen,
|
||||
static char *
|
||||
linker_search_kld(const char *name)
|
||||
{
|
||||
char *cp, *ep, *result, **cpp;
|
||||
int extlen, len;
|
||||
char *cp, *ep, *result;
|
||||
int len;
|
||||
|
||||
/* qualified at all? */
|
||||
if (index(name, '/'))
|
||||
return (linker_strdup(name));
|
||||
|
||||
extlen = 0;
|
||||
for (cpp = linker_ext_list; *cpp; cpp++) {
|
||||
len = strlen(*cpp);
|
||||
if (len > extlen)
|
||||
extlen = len;
|
||||
}
|
||||
extlen++; /* trailing '\0' */
|
||||
|
||||
/* traverse the linker path */
|
||||
len = strlen(name);
|
||||
for (ep = linker_path; *ep; ep++) {
|
||||
|
Loading…
Reference in New Issue
Block a user