Changeset 1678 for trunk/src/win32k/ldr


Ignore:
Timestamp:
Nov 10, 1999, 2:45:38 AM (26 years ago)
Author:
bird
Message:

Some bugsfixes - Yield is disabled.
Added parameters.
Correcte moduleheaders.
Introduced a new base class for virtual lx modules + some elf sketches.

Location:
trunk/src/win32k/ldr
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/win32k/ldr/ldr.cpp

    r1535 r1678  
    1 /* $Id: ldr.cpp,v 1.5 1999-10-31 23:57:05 bird Exp $
     1/* $Id: ldr.cpp,v 1.6 1999-11-10 01:45:36 bird Exp $
    22 *
    33 * ldr.cpp - Loader helpers.
    44 *
    55 * Copyright (c)  1999 knut  St.  osmundsen
     6 *
     7 * Project Odin Software License can be found in LICENSE.TXT
    68 *
    79 */
     
    2931#include <exe386.h>
    3032#include "OS2Krnl.h"
     33#include "ModuleBase.h"
    3134#include "pe2lx.h"
    3235#include "avl.h"
     
    125128 * @param     pMTE    Pointer to MTE. NULL is valid.
    126129 * @param     fFlags  Type flags for the fFlags field in the node.
    127  * @param     pvData  Pointer to data.
     130 * @param     pModObj Pointer to module object.
    128131 * @sketch    DEBUG: check that the module doesn't exists and parameter check.
    129132 *            (try) Allocate a new node. (return errorcode on failure)
     
    135138 * @author    knut st. osmundsen
    136139 */
    137 ULONG       addModule(SFN hFile, PMTE pMTE, ULONG fFlags, void *pvData)
     140ULONG       addModule(SFN hFile, PMTE pMTE, ULONG fFlags, ModuleBase *pModObj)
    138141{
    139142    PMODULE pMod;
     
    166169    pMod->pMTE = pMTE;
    167170    pMod->fFlags = fFlags;
    168     pMod->Data.pv = pvData;
     171    pMod->Data.pModule = pModObj;
    169172
    170173    /* insert the module node into the tree(s) */
     
    248251    pMTERoot = NULL;
    249252
    250     /* Pe2Lx logging. */
    251     Pe2Lx::ulInfoLevel = options.ulInfoLevel;
     253    /* ModuleBase logging. */
     254    ModuleBase::ulInfoLevel = options.ulInfoLevel;
    252255
    253256    return rc;
  • trunk/src/win32k/ldr/myLDRQAppType.cpp

    r847 r1678  
    1 /* $Id: myLDRQAppType.cpp,v 1.1 1999-09-06 02:20:01 bird Exp $
     1/* $Id: myLDRQAppType.cpp,v 1.2 1999-11-10 01:45:36 bird Exp $
    22 *
    33 * _myLDRQAppType - _LDRQAppType overload.
    44 *
    55 * Copyright (c) 1998-1999 knut  St.  osmundsen
     6 *
     7 * Project Odin Software License can be found in LICENSE.TXT
    68 *
    79 */
  • trunk/src/win32k/ldr/myldrClose.cpp

    r1467 r1678  
    1 /* $Id: myldrClose.cpp,v 1.3 1999-10-27 02:02:58 bird Exp $
     1/* $Id: myldrClose.cpp,v 1.4 1999-11-10 01:45:36 bird Exp $
    22 *
    33 * myldrClose - _ldrClose
    44 *
    55 * Copyright (c) 1998-1999 knut st. osmundsen
     6 *
     7 * Project Odin Software License can be found in LICENSE.TXT
    68 *
    79 */
     
    2527#include <exe386.h>
    2628#include "OS2Krnl.h"
    27 #include "pe2lx.h"
    2829#include "avl.h"
     30#include "ModuleBase.h"
    2931#include "ldr.h"
    3032#include "ldrCalls.h"
     
    4547    if (GetState(hFile) == HSTATE_OUR)
    4648    {
     49        #ifdef DEBUG
     50        PMODULE pMod = getModuleBySFN(hFile);
     51        if (pMod != NULL)
     52            pMod->Data.pModule->dumpVirtualLxFile();
     53        else
     54            kprintf(("_ldrClose: getModuleBySFN failed!!!"));
     55        #endif
     56
    4757        rc = removeModule(hFile);
    4858        if (rc != NO_ERROR)
  • trunk/src/win32k/ldr/myldrOpen.cpp

    r1535 r1678  
    1 /* $Id: myldrOpen.cpp,v 1.4 1999-10-31 23:57:06 bird Exp $
     1/* $Id: myldrOpen.cpp,v 1.5 1999-11-10 01:45:36 bird Exp $
    22 *
    33 * myldrOpen - _ldrOpen.
    44 *
    55 * Copyright (c) 1998-1999 knut st. osmundsen
     6 *
     7 * Project Odin Software License can be found in LICENSE.TXT
    68 *
    79 */
     
    2729#include <exe386.h>
    2830#include "OS2Krnl.h"
     31#include "ModuleBase.h"
    2932#include "pe2lx.h"
    3033#include "elf.h"
     
    128131                }
    129132                else
    130                     if (*pach == '#')
     133                    if (*pach == '#' && pach[1] == '!')
    131134                    {
    132135                        /* unix styled script...? Must be more than 64 bytes long? No options. firstline < 64 bytes. */
    133                         char *pszStart = pach+1;
     136                        char *pszStart = pach+2;
    134137                        char *pszEnd;
    135138                        kprintf(("_ldrOpen: unix script?\n"));
     
    142145                        if (*pszStart != '\0' && *pszStart != '\r' && *pszStart != '\n')
    143146                        {   /* find end-of-word */
     147                            pszEnd = pszStart + 1;
    144148                            while (*pszEnd != '\0' && *pszEnd != '\n' && *pszEnd != '\r'
    145149                                   && *pszEnd != '\t' && *pszEnd != ' ')
    146150                                pszEnd++;
    147                             *pszEnd = '\0';
    148151                            if (*pszEnd != '\0')
    149152                            {
     153                                *pszEnd = '\0';
    150154                                kprintf(("_ldrOpen: unix script - opening %s\n", pszStart));
    151155                                _ldrClose(*phFile);
  • trunk/src/win32k/ldr/myldrRead.cpp

    r1467 r1678  
    1 /* $Id: myldrRead.cpp,v 1.4 1999-10-27 02:02:58 bird Exp $
     1/* $Id: myldrRead.cpp,v 1.5 1999-11-10 01:45:36 bird Exp $
    22 *
    33 * myldrRead - _ldrRead.
    44 *
    55 * Copyright (c) 1998-1999 knut st. osmundsen
     6 *
     7 * Project Odin Software License can be found in LICENSE.TXT
    68 *
    79 */
     
    2628#include <exe386.h>
    2729#include "OS2Krnl.h"
     30#include "ModuleBase.h"
    2831#include "pe2lx.h"
    2932#include "avl.h"
     
    6164
    6265            if ((pMod->fFlags & MOD_TYPE_MASK) == MOD_TYPE_PE2LX)
    63                 rc = pMod->Data.pPe2Lx->read(ulOffset, pBuffer, ulBytesToRead, ulFlags, pMTE);
     66                rc = pMod->Data.pModule->read(ulOffset, pBuffer, ulBytesToRead, ulFlags, pMTE);
    6467            else
    6568            {
Note: See TracChangeset for help on using the changeset viewer.