Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Next revisionBoth sides next revision | ||
en:docs:fapi:dosallochuge [2021/09/16 13:07] – prokushev | en:docs:fapi:dosallochuge [2021/09/16 13:09] – prokushev | ||
---|---|---|---|
Line 62: | Line 62: | ||
**Note:** This request may be issued from privilege level 2. However, the segment is allocated as a privilege level 3 segment. | **Note:** This request may be issued from privilege level 2. However, the segment is allocated as a privilege level 3 segment. | ||
- | ===Family API Considerations=== | + | ===== Family API Considerations ===== |
Some options operate differently in the DOS mode than in the OS/2 mode. Therefore, the following considerations apply to DosAllocHuge when coding for the DOS mode: | Some options operate differently in the DOS mode than in the OS/2 mode. Therefore, the following considerations apply to DosAllocHuge when coding for the DOS mode: | ||
Line 69: | Line 70: | ||
* Selector is the actual segment address allocated. | * Selector is the actual segment address allocated. | ||
- | ==Example Code== | + | ===== Example Code ===== |
- | === C Binding=== | + | |
+ | ==== C Binding | ||
<code c> | <code c> | ||
Line 87: | Line 89: | ||
</ | </ | ||
- | === Example === | + | ==== Example |
This example requests a block of memory with 4 segments, the last segment having 1,040 bytes. The block of memory will never be larger than 8 segments. The memory can be shared with DosGiveSeg API calls. The system can discard the memory if it needs too. | This example requests a block of memory with 4 segments, the last segment having 1,040 bytes. The block of memory will never be larger than 8 segments. The memory can be shared with DosGiveSeg API calls. The system can discard the memory if it needs too. | ||
Line 109: | Line 111: | ||
</ | </ | ||
- | === ASM Binding === | + | ==== MASM Binding ==== |
<code asm> | <code asm> | ||
EXTRN DosAllocHuge: | EXTRN DosAllocHuge: |