FSH SEGREALLOC: Difference between revisions
Appearance
Created page with "This function changes the size of a segment previously allocated with FSH_ SEGALLOC or loaded as part of the FSD image. ==Syntax== FSH_SEGREALLOC(sel, cbSeg) ==Parameter..." |
mNo edit summary |
||
Line 1: | Line 1: | ||
This function changes the size of a segment previously allocated with | This function changes the size of a segment previously allocated with FSH_SEGALLOC or loaded as part of the FSD image. | ||
==Syntax== | ==Syntax== | ||
FSH_SEGREALLOC(sel, cbSeg) | |||
==Parameters== | ==Parameters== | ||
;sel: is the selector to be changed. | ;sel: is the selector to be changed. | ||
;cbSeg: is the new size to set for the segment. | |||
==Returns== | ==Returns== | ||
If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned: | If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned: | ||
*ERROR_NOT_ENOUGH_MEMORY too much memory is allocated. | |||
*ERROR_INVALID_ACCESS the selector is invalid | |||
==Calling Sequence== | ==Calling Sequence== | ||
<PRE> | <PRE> | ||
Line 20: | Line 20: | ||
unsigned long cbSeg; | unsigned long cbSeg; | ||
</PRE> | </PRE> | ||
==Remarks== | ==Remarks== | ||
The segment may be grown or shrunk. The segment may be moved in the process. When grown, the extra space is uninitialized. | The segment may be grown or shrunk. The segment may be moved in the process. When grown, the extra space is uninitialized. | ||
FSH_SEGREALLOC may block. | FSH_SEGREALLOC may block. | ||
;Note: | ;Note: OS/2 does not validate input parameters. An FSD, therefore, should call FSH_PROBEBUF where appropriate. | ||
[[Category:IFS Interfaces]] | [[Category:IFS Interfaces]] | ||
{{DISPLAYTITLE:FSH_SEGREALLOC}} | {{DISPLAYTITLE:FSH_SEGREALLOC}} |
Latest revision as of 05:42, 20 February 2020
This function changes the size of a segment previously allocated with FSH_SEGALLOC or loaded as part of the FSD image.
Syntax
FSH_SEGREALLOC(sel, cbSeg)
Parameters
- sel
- is the selector to be changed.
- cbSeg
- is the new size to set for the segment.
Returns
If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned:
- ERROR_NOT_ENOUGH_MEMORY too much memory is allocated.
- ERROR_INVALID_ACCESS the selector is invalid
Calling Sequence
int far pascal FSH_SEGREALLOC(sel, cbSeg) unsigned short sel; unsigned long cbSeg;
Remarks
The segment may be grown or shrunk. The segment may be moved in the process. When grown, the extra space is uninitialized.
FSH_SEGREALLOC may block.
- Note
- OS/2 does not validate input parameters. An FSD, therefore, should call FSH_PROBEBUF where appropriate.