Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
en:docs:fapi:dossetmaxfh [2021/09/19 05:49] – created prokushev | en:docs:fapi:dossetmaxfh [2021/11/04 13:29] (current) – prokushev | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | {{page> | ||
+ | |||
+ | ====== DosSetMaxFH ====== | ||
+ | |||
This call defines the maximum number of file handles for the current process. | This call defines the maximum number of file handles for the current process. | ||
- | ==Syntax== | + | ===== Syntax ===== |
+ | <code c> | ||
| | ||
+ | </ | ||
+ | ===== Parameters ===== | ||
- | ==Parameters== | + | * NumberHandles (USHORT) - input : Total number of file handles to be provided. |
- | ;NumberHandles (USHORT) - input : Total number of file handles to be provided. | + | |
- | ==Return Code== | + | ===== Return Code ===== |
- | ;rc (USHORT) - return: | + | |
- | *0 NO_ERROR | + | rc (USHORT) - return: |
- | *8 ERROR_NOT_ENOUGH_MEMORY | + | |
- | *87 ERROR_INVALID_PARAMETER | + | |
+ | *8 ERROR_NOT_ENOUGH_MEMORY | ||
+ | *87 ERROR_INVALID_PARAMETER | ||
+ | |||
+ | ===== Remarks ===== | ||
- | ==Remarks== | ||
OS/2 initially allots 20 file handles to a process, which is the recommended amount for an application. However, if the system limit has not been reached, this amount can be increased with DosSetMaxFH. When this call is made, all open file handles are preserved. | OS/2 initially allots 20 file handles to a process, which is the recommended amount for an application. However, if the system limit has not been reached, this amount can be increased with DosSetMaxFH. When this call is made, all open file handles are preserved. | ||
- | ==Bindings== | + | ===== Bindings |
- | ===C=== | + | |
- | <PRE> | + | ====C==== |
+ | <code c> | ||
#define INCL_DOSFILEMGR | #define INCL_DOSFILEMGR | ||
Line 25: | Line 35: | ||
USHORT | USHORT | ||
USHORT | USHORT | ||
- | </PRE> | + | </code> |
- | ===MASM=== | + | ====MASM==== |
- | <PRE> | + | <code asm> |
EXTRN DosSetMaxFH: | EXTRN DosSetMaxFH: | ||
INCL_DOSFILEMGR | INCL_DOSFILEMGR | ||
Line 36: | Line 46: | ||
Returns WORD | Returns WORD | ||
- | </PRE> | + | </code> |
- | [[Category:Dos16]] | + | {{page> |