Ignore:
Timestamp:
Jul 17, 2000, 12:43:41 AM (25 years ago)
Author:
bird
Message:

Checkin of current code in the Grace brance for backup purpose.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GRACE/src/win32k/ldr/ldr.cpp

    r2501 r3834  
    1 /* $Id: ldr.cpp,v 1.7 2000-01-22 18:21:01 bird Exp $
     1/* $Id: ldr.cpp,v 1.7.4.1 2000-07-16 22:43:34 bird Exp $
    22 *
    33 * ldr.cpp - Loader helpers.
     
    2828
    2929#include "log.h"
     30#include "avl.h"
    3031#include <peexe.h>
    3132#include <exe386.h>
    3233#include "OS2Krnl.h"
     34#include "ldr.h"
     35#include "ldrCalls.h"
    3336#include "ModuleBase.h"
    3437#include "pe2lx.h"
    35 #include "avl.h"
    36 #include "ldr.h"
    3738#include "options.h"
    3839
     
    4142*   Global Variables                                                           *
    4243*******************************************************************************/
    43 PAVLNODECORE    pSFNRoot = NULL;
    44 PAVLNODECORE    pMTERoot = NULL;
    45 
     44static PAVLNODECORE    pSFNRoot = NULL;
     45static PAVLNODECORE    pMTERoot = NULL;
     46
     47
     48/*
     49 * Loader State. (See ldr.h for more info.)
     50 */
     51ULONG          ulLdrState = LDRSTATE_UNKNOWN;
     52
     53
     54/*
     55 * Pointer to the executable module being loaded.
     56 * This pointer is set by ldrOpen and cleared by tkExecPgm.
     57 * It's hence only valid at tkExecPgm time. (isLdrStateExecPgm() == TRUE).
     58 */
     59PMODULE         pExeModule = NULL;
     60
     61
     62/*
     63 * Filehandle bitmap.
     64 */
    4665unsigned char   achHandleStates[MAX_FILE_HANDLES/8];
     66
     67
    4768
    4869
     
    6485 * Gets a module by the MTE.
    6586 * @returns   Pointer to module node. If not found NULL.
    66  * @param     pMTE  Pointer an Module Table Entry.
     87 * @param     pMTE  Pointer a Module Table Entry.
    6788 * @sketch    Try find it in the MTE tree.
    6889 *            IF not found THEN
     
    124145
    125146/**
     147 * Gets a module by the hMTE.
     148 * @returns   Pointer to module node. If not found NULL.
     149 * @param     hMTE  Handle to a Module Table Entry.
     150 * @sketch    Convert hMte to an pMTE (pointer to MTE).
     151 *            Call getModuleByMTE with MTE pointer.
     152 * @status    completely implemented.
     153 * @author    knut st. osmundsen
     154 */
     155PMODULE     getModuleByhMTE(HMTE hMTE)
     156{
     157    PMTE pMTE;
     158
     159    pMTE = ldrValidateMteHandle(hMTE);
     160    if (pMTE != NULL)
     161        return getModuleByMTE(pMTE);
     162
     163    return NULL;
     164}
     165
     166
     167/**
    126168 * Get a module by filename.
    127169 * @returns   Pointer to module node. If not found NULL.
Note: See TracChangeset for help on using the changeset viewer.