Ignore:
Timestamp:
Aug 22, 1999, 5:11:35 PM (26 years ago)
Author:
sandervl
Message:

Exception handler changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/windll.cpp

    r617 r624  
    1 /* $Id: windll.cpp,v 1.11 1999-08-22 11:11:11 sandervl Exp $ */
     1/* $Id: windll.cpp,v 1.12 1999-08-22 15:11:35 sandervl Exp $ */
    22
    33/*
     
    123123BOOL Win32Dll::init(ULONG reservedMem)
    124124{
     125 char   modname[CCHMAXPATH];
    125126 char  *syspath;
    126127 FILE  *dllfile;
     
    130131  if(fSystemDll == FALSE && fNativePEImage == TRUE)
    131132  {//might be win32 dll, so check this
     133        strupr(szFileName);
     134        if(!strstr(szFileName, ".DLL")) {
     135                strcat(szFileName,".DLL");
     136        }
    132137        dllfile = fopen(szFileName, "r");
    133138        if(dllfile == NULL) {//search in libpath for dll
    134139                syspath = getenv("WIN32LIBPATH");
    135140                if(syspath) {
    136                         strcpy(szModule, syspath);
    137                         if(szModule[strlen(szModule)-1] != '\\') {
    138                                 strcat(szModule, "\\");
     141                        strcpy(modname, syspath);
     142                        if(modname[strlen(modname)-1] != '\\') {
     143                                strcat(modname, "\\");
    139144                        }
    140                         strcat(szModule, szFileName);
    141                         szFileName = szModule;
     145                        strcat(modname, szFileName);
     146                        strcpy(szFileName, modname);
    142147                }
    143148        }
     
    278283  tlsAttachThread();    //setup TLS (main thread)
    279284
    280   if(fSystemDll || fSkipEntryCalls) {
     285  if(fSystemDll || fSkipEntryCalls || dllEntryPoint == NULL) {
    281286        dprintf(("attachProcess not required for dll %s", szModule));
    282287        return(TRUE);
     
    305310 BOOL rc;
    306311
    307   if(fSystemDll || fSkipEntryCalls) {
     312  if(fSystemDll || fSkipEntryCalls || dllEntryPoint == NULL) {
    308313        tlsDetachThread();      //destroy TLS (main thread)
    309314        return(TRUE);
     
    334339 BOOL               rc;
    335340
    336   if(fSystemDll || fSkipEntryCalls)
     341  if(fSystemDll || fSkipEntryCalls || dllEntryPoint == NULL)
    337342        return(TRUE);
    338343
     
    354359 BOOL               rc;
    355360
    356   if(fSystemDll || fSkipEntryCalls)
     361  if(fSystemDll || fSkipEntryCalls || dllEntryPoint == NULL)
    357362        return(TRUE);
    358363
Note: See TracChangeset for help on using the changeset viewer.