Changeset 550 for trunk/include


Ignore:
Timestamp:
Aug 18, 1999, 7:18:01 PM (26 years ago)
Author:
sandervl
Message:

PE loader changes

Location:
trunk/include
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/nameid.h

    r10 r550  
    1 /* $Id: nameid.h,v 1.2 1999-05-27 15:17:58 phaller Exp $ */
     1/* $Id: nameid.h,v 1.3 1999-08-18 17:16:05 sandervl Exp $ */
    22
    33/*
     
    1717int SYSTEM ConvertNameId(ULONG hModule, char *);
    1818
    19 void SYSTEM UpCase(char *mixedcase);
    20 
    2119#ifndef ULONG
    2220#define ULONG unsigned long
     
    2422
    2523ULONG GetOS2ModuleHandle(ULONG hmod);
     24char *StripPath(char *path);
    2625
    2726#ifdef __cplusplus
  • trunk/include/windll.h

    r544 r550  
    1 /* $Id: windll.h,v 1.4 1999-08-18 12:24:52 sandervl Exp $ */
     1/* $Id: windll.h,v 1.5 1999-08-18 17:16:05 sandervl Exp $ */
    22
    33/*
     
    1717#include "winimage.h"
    1818
    19 #ifndef CCHMAXPATH
    20 #define CCHMAXPATH 260
    21 #endif
    2219#ifndef HINSTANCE
    2320#define HINSTANCE ULONG
     
    8986private:
    9087        ULONG     referenced;
    91         char      szModule[CCHMAXPATH];
    92 
    93         char     *StripPath(char *path);
    9488
    9589
  • trunk/include/winimage.h

    r544 r550  
    1 /* $Id: winimage.h,v 1.5 1999-08-18 12:24:53 sandervl Exp $ */
     1/* $Id: winimage.h,v 1.6 1999-08-18 17:16:05 sandervl Exp $ */
    22
    33/*
     
    2727#endif
    2828
     29#ifndef CCHMAXPATH
     30#define CCHMAXPATH 260
     31#endif
    2932
    3033//SvL: Amount of memory the peldr dll reserves for win32 exes without fixups
     
    125128        char *getFullPath()           { return fullpath; };
    126129
     130        char *getModuleName()         { return szModule; };
     131
    127132        HRSRC   findResourceA(LPCSTR lpszName, LPSTR lpszType);
    128133        HRSRC   findResourceW(LPWSTR lpszName, LPWSTR lpszType);
     
    163168     Section *findSectionByAddr(ULONG addr);
    164169
    165         BOOL  storeSections();
     170        BOOL  storeSections(char *win32file);
    166171        BOOL  setMemFlags();
    167172        BOOL  setFixups(PIMAGE_BASE_RELOCATION prel);
     
    182187        Win32Resource            *winres;
    183188
    184         IMAGE_OPTIONAL_HEADER oh;
    185         IMAGE_FILE_HEADER     fh;
     189        IMAGE_OPTIONAL_HEADER oh;
     190        IMAGE_FILE_HEADER     fh;
    186191
    187192        ULONG                 errorState, entryPoint;
     
    193198        ULONG                 nrsections, imageSize, imageVirtBase, imageVirtEnd;
    194199        //OS/2 virtual base address
    195         ULONG                 baseAddress, realBaseAddress;
     200        ULONG                 realBaseAddress;
    196201        Section               section[MAX_SECTION];
    197202
    198203        char                 *szFileName, *fullpath;
     204        char                  szModule[CCHMAXPATH];
    199205
    200206        HINSTANCE             hinstance;
     
    226232extern ofstream fout;
    227233
     234//SvL: This structure is placed at the end of the first page of the image (header
     235//     page), so we can determine the Win32Image pointer from a HINSTANCE variable
     236//     (which is actually the address of the win32 module)
     237typedef struct
     238{
     239  Win32Image *image;
     240  ULONG       magic;
     241} WINIMAGE_LOOKUP;
     242
     243#define WINIMAGE_LOOKUPADDR(a)  (WINIMAGE_LOOKUP *)((ULONG)a + PAGE_SIZE - sizeof(WINIMAGE_LOOKUP))
     244
    228245#endif //__PE2LX__
    229246
Note: See TracChangeset for help on using the changeset viewer.