made search for .dll in plug-in names case insensitive

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@3511 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
kichik 2004-03-11 19:29:04 +00:00
parent d8201ccded
commit a05b0f6c61
2 changed files with 15 additions and 5 deletions

View file

@ -51,7 +51,7 @@ void Plugins::FindCommands(char* path,bool displayInfo)
}
}
void Plugins::GetExports(char* pathToDll,bool displayInfo)
void Plugins::GetExports(char* pathToDll, bool displayInfo)
{
if (pathToDll)
{
@ -64,8 +64,18 @@ void Plugins::GetExports(char* pathToDll,bool displayInfo)
dllName[0] = 0;
char* ptr = strrchr(pathToDll,'\\');
if (ptr && *ptr && *(ptr+1)) strcpy(dllName,ptr+1);
ptr = strstr(dllName, ".dll");
if (ptr) *ptr = 0;
// find .dll
char *dllName2 = strdup(dllName);
for (ptr = dllName2; *ptr; ptr = CharNext(ptr))
{
if (!strcmpi(ptr, ".dll"))
{
*(dllName + (ptr - dllName2)) = 0;
break;
}
}
free(dllName2);
FILE* dll = fopen(pathToDll,"rb");
if (dll)

View file

@ -3442,8 +3442,8 @@ int CEXEBuild::doCommand(int which_token, LineParser &line)
char b[255];
for (unsigned int spos=0; (spos <= strlen(s)) && (spos <= 255); spos++)
b[spos]=toupper(*(s+spos));
strcpy(s,b);
strcpy(s,b);
if (*s)
{
int c=0;