Logo Search packages:      
Sourcecode: virtualbox-ose version File versions  Download package

static KLDRADDR kldrModNativeSize ( PKLDRMOD  pMod  )  [static]

Get the size of the mapped module.

Returns:
The size of the mapped module (in bytes).
Parameters:
pMod The module.

Definition at line 1065 of file kLdrModNative.c.

References K_OS_DARWIN, and KLDRMOD::pvData.

{
#if K_OS == K_OS_OS2
    return 0; /* don't bother */

#elif K_OS == K_OS_WINDOWS || defined(__NT__)
    /* just because we can. */
    PKLDRMODNATIVE pModNative = (PKLDRMODNATIVE)pMod->pvData;
    return pModNative->pNtHdrs->OptionalHeader.SizeOfImage;

#elif K_OS == K_OS_DARWIN
    /** @todo Implement me on Darwin. */
    return 0;

#else
# error "Port me"
#endif
}


Generated by  Doxygen 1.6.0   Back to index