This is an old revision of the document!
Table of Contents
This is part of Win16 API which allow to create versions of program from one source code to run under OS/2 and Win16. Under OS/2 program can be running under Win-OS/2 if program is Windows NE executable, and with help on Windows Libraries for OS/2, if it is OS/2 NE executable. Here is a WLO to OS/2 API mapping draft
LocalCountFree
Brief
[Undocumented] Returns the number of free entries (or free space) in the local heap.
Syntax
UINT WINAPI LocalCountFree( HANDLE hHeap );
Parameters
hHeap – Handle (selector) of the segment that contains the local heap. If hHeap is zero, the function operates on the current data segment (DGROUP) .
Return Value
Returns the number of free entries (or free bytes) in the local heap. The exact meaning of the return value is not documented.
Notes
Presumably, the function was used for debugging or monitoring the state of the local heap, allowing a program to determine the degree of fragmentation.
Example Code
C Binding
#include <windows.h> // Hypothetical usage UINT uFreeCount = LocalCountFree(0);
MASM Binding
; AX = 0 (current data segment) push ax ; hHeap call LocalCountFree ; Returns AX = number of free entries




