Product Documentation

FairCom ISAM for C

Previous Topic

Next Topic

ctThrdLIFOWriteDirect

Short Name

ctThrdLIFOWriteDirect()

Type

Threading function

Declaration

NINT ctThrdLIFOWriteDirect(NINT qid, pVOID message, NINT msglen)

Description

ctThrdLIFOWriteDirect() adds the address for queue entry message of length msglen to the front of queue qid. Unlike ctThrdLIFOWrite(), which copies the contents of the entry into a buffer allocated by the queue write call, ctThrdLIFOWriteDirect() uses pointers to buffers created by the application to manage messages.

Note: The application is responsible for managing the buffers used in the ctThrdQueueReadDirect(), ctThrdQueueWriteDirect(), and ctThrdLIFOWriteDirect() calls. To avoid memory/buffer errors, FairCom recommends using either the original Queue read/write calls or the new direct calls, but not mixing calls from both pairs.

The return value is an error indicator.

Return Values

Value

Symbolic Constant

Explanation

0

NO_ERROR

Successful queue write.

90

NQUE_ERR

Invalid qid.

92

QMRT_ERR

Queue memory error.

514

CQUE_ERR

Queue could not be closed.

See FairCom DB Error Codes for a complete listing of valid FairCom DB error values.See c-tree Plus Error Codes for a complete listing of valid c-tree Plus error values.

See Also

ctThrdQueueWriteDirect, ctThrdLIFOWrite

TOCIndex