DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Developing applications using XTI or TLI

Synchronous and asynchronous operation

Some of the functions in XTI can operate either synchronously or asynchronously. In synchronous mode, a function call does not return until the operation can be completed (or until an error is detected). For example, if a process calls t_rcv in synchronous mode and no data is available, the call blocks until data arrives at the transport endpoint. On the other hand, if the process calls t_rcv in asynchronous mode and no data is available, the call returns immediately with a value of -1 and the global variable t_errno is set to TNODATA. It is then up to the process to decide when and how to try again and call t_rcv later.

The functions that can operate either synchronously or asynchronously are:

A process usually indicates whether these functions will operate synchronously or asynchronously be setting the oflag argument to t_open to O_NONBLOCK. See the t_open manual page for for more information.
Next topic: Flow of transmitted data
Previous topic: Connectionless service

© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003