Changeset 3399 for trunk/src


Ignore:
Timestamp:
Apr 16, 2000, 8:47:22 AM (25 years ago)
Author:
bird
Message:

Corrected bug - WinExe might be NULL during intiation. Currently we'll
ignore the executable path. (temprorary fix!)

File:
1 edited

Legend:

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

    r3398 r3399  
    1 /* $Id: winimagebase.cpp,v 1.16 2000-04-16 04:27:37 bird Exp $ */
     1/* $Id: winimagebase.cpp,v 1.17 2000-04-16 06:47:22 bird Exp $ */
    22
    33/*
     
    269269                     *      slashes are backslashes!
    270270                     */
     271                    if (!WinExe) continue;
    271272                    pszPath = strcpy(plv->szPath, WinExe->getFullPath());
    272273                }
     
    455456//******************************************************************************
    456457//******************************************************************************
     458/**
     459 * Checks if a file is a PE executable image valid to be executed on this machine.
     460 * @returns   FALSE if not PE image.
     461 *            > 0 if valid PE image.
     462 *                1 DLL
     463 *                2 EXE
     464 * @param     szFilename    Pointer to filename
     465 * @author    knut st. osmundsen (knut.stange.osmundsen@pmsc.no)
     466 * @remark    Should not call findDll!
     467 */
    457468BOOL Win32ImageBase::isPEImage(char *szFileName)
    458469{
     
    539550  }
    540551  DosClose(win32handle);
    541   return(TRUE);
     552  return (fh.Characteristics & IMAGE_FILE_DLL ? 1 : 2);
    542553
    543554failure:
Note: See TracChangeset for help on using the changeset viewer.