FSH BUFSTATE: Difference between revisions
Appearance
No edit summary |
|||
Line 3: | Line 3: | ||
|Remarks=REMOVED in OS/2 Version 2.0 | |Remarks=REMOVED in OS/2 Version 2.0 | ||
}} | }} | ||
FSH_BUFSTATE is used retrieve or set the state of a buffer. | |||
==Syntax== | ==Syntax== | ||
FSH_BUFSTATE (pBuf, flag, pState) | FSH_BUFSTATE (pBuf, flag, pState) | ||
==Parameters== | ==Parameters== | ||
; pBuf: pointer to buffer. This pointer was returned to the FSD | ; pBuf : pointer to buffer. This pointer was returned to the FSD by FSH_GETBUFFER | ||
; flag: indicates get or set buf state. | |||
; flag : indicates get or set buf state. | |||
:*flag == 0 indicates retrieve state | :*flag == 0 indicates retrieve state | ||
:*flag == 1 indicates set state | :*flag == 1 indicates set state | ||
;pState : for set, points to new state of buffer on input. For retrieve, points to state of buffer. | |||
:State == 0x00000080 indicates dirty buffer. | |||
:All other values are reserved. | |||
==Returns== | ==Returns== | ||
Error code if error detected, 0 otherwise. | |||
ERROR_INVALID_PARAMETER - pointer to buffer is invalid or reserved state bits are set. | |||
==Calling Sequence== | ==Calling Sequence== | ||
<PRE> | <PRE> | ||
int | int pascal FSH_BUFSTATE (pBuf, flag, pState) | ||
char | char * pBuf; | ||
unsigned | unsigned long flag; | ||
unsigned | unsigned long * pState; | ||
</PRE> | </PRE> | ||
==Remarks== | ==Remarks== | ||
;Note : To set the opposite of a defined state, call FSH_BUFSTATE with the bit not set. For example, to set a buffer not dirty, pass 0x00000000 as the new state. | |||
;Reminder: OS/2 does not validate input parameters, so FSD should call FSH_PROBEBUF where appropriate. | |||
[[Category:IFS Interfaces]] | [[Category:IFS Interfaces]] | ||
{{DISPLAYTITLE:FSH_BUFSTATE}} | {{DISPLAYTITLE:FSH_BUFSTATE}} |
Latest revision as of 15:59, 20 February 2020
![]() | |
---|---|
It is recommended to use a newer replacement for this function. | |
Replacement: | |
Remarks: | REMOVED in OS/2 Version 2.0 |
FSH_BUFSTATE is used retrieve or set the state of a buffer.
Syntax
FSH_BUFSTATE (pBuf, flag, pState)
Parameters
- pBuf
- pointer to buffer. This pointer was returned to the FSD by FSH_GETBUFFER
- flag
- indicates get or set buf state.
- flag == 0 indicates retrieve state
- flag == 1 indicates set state
- pState
- for set, points to new state of buffer on input. For retrieve, points to state of buffer.
- State == 0x00000080 indicates dirty buffer.
- All other values are reserved.
Returns
Error code if error detected, 0 otherwise.
ERROR_INVALID_PARAMETER - pointer to buffer is invalid or reserved state bits are set.
Calling Sequence
int pascal FSH_BUFSTATE (pBuf, flag, pState) char * pBuf; unsigned long flag; unsigned long * pState;
Remarks
- Note
- To set the opposite of a defined state, call FSH_BUFSTATE with the bit not set. For example, to set a buffer not dirty, pass 0x00000000 as the new state.
- Reminder
- OS/2 does not validate input parameters, so FSD should call FSH_PROBEBUF where appropriate.