mirror of
git://source.winehq.org/git/wine.git
synced 2024-11-02 12:03:45 +00:00
Only try to append ".dll" if a library is loaded implicitely.
This commit is contained in:
parent
edda358400
commit
014855850e
1 changed files with 7 additions and 5 deletions
|
@ -849,11 +849,13 @@ HINSTANCE16 NE_LoadModule( LPCSTR name, BOOL implicit )
|
|||
{
|
||||
char buffer[260];
|
||||
|
||||
/* 4 == strlen(".dll") */
|
||||
strncpy(buffer, name, sizeof(buffer) - 1 - 4);
|
||||
strcat(buffer, ".dll");
|
||||
if ((hFile = OpenFile16( buffer, &ofs, OF_READ )) == HFILE_ERROR16) {
|
||||
return 2; /* File not found */
|
||||
if(implicit)
|
||||
{
|
||||
/* 4 == strlen(".dll") */
|
||||
strncpy(buffer, name, sizeof(buffer) - 1 - 4);
|
||||
strcat(buffer, ".dll");
|
||||
if ((hFile = OpenFile16( buffer, &ofs, OF_READ )) == HFILE_ERROR16)
|
||||
return 2; /* File not found */
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue