Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
DosFreeModule (1.2)
◄Function Group► ◄Overview► ◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
#define INCL_DOSMODULEMGR
USHORT DosFreeModule(hmod)
HMODULE hmod; /* module handle */
The DosFreeModule function frees the specified dynamic-link module. After a
process has freed a module, any function addresses the process may have
retrieved from the module are no longer valid; a protection fault occurs if
these functions are called.
Parameter Description
────────────────────────────────────────────────────────────────────────────
hmod Identifies the dynamic-link module to free. This handle must have
been created previously by using the DosLoadModule or
DosGetModName function.
Return Value
The return value is zero if the function is successful. Otherwise, it is an
error value, which may be one of the following:
ERROR_INTERRUPT
ERROR_INVALID_HANDLE
Comments
If other processes have loaded the module and not yet freed it, the module
remains in system memory for those processes. The system does not remove a
module from memory until it is no longer used by any process.
See Also
DosGetModName, DosLoadModule
♦