[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Communications Technical Reference, Volume 2

t_rcvuderr Subroutine for X/Open Transport Interface

Purpose

Receive a unit data error indication.

Library

X/Open Transport Interface Library (libxti.a)

Syntax

#include <xti.h>
int t_rcvuderr (fd, uderr)
int fd;
struct t_uderr *uderr;

Description

The t_rcvuderr subroutine is used in connectionless mode to receive information concerning an error on a previously sent data unit, and should only be issued following a unit data error indication. It informs the transport user that a data unit with a specific destination address and protocol options produced an error.

Parameters

fd Identifies the local transport endpoint through which the error report will be received.
uderr Points to a t_uderr structure containing the following members:
struct netbuf addr;
struct netbuf opt;
long error;

The maxlen field of add and opt must be set before calling this subroutine to indicate the maximum size of the buffer for each.

On return from this call:

addr Specifies the destination protocol address of the erroneous data unit.
opt Identifies options that were associated with the data unit.
error Specifies a protocol-dependent error code.

If the user does not care to identify the data unit that produced an error, uderr may be set to a null pointer, and the t_rcvuderr subroutine simply clears the error indication without reporting any information to the user.

Valid States

T_IDLE

Return Values

0 Successful completion.
-1 t_errno is set to indicate an error.

Error Codes

On failure, t_errno is set to one of the following:

TBADF The specified file descriptor does not refer to a transport endpoint.
TBUFOVFLW The number of bytes allocated for the incoming protocol address or options (maxlen) is greater than 0 but not sufficient to store the information. The unit data information to be returned in the uderr parameter is discarded.
TNOTSUPPORT This subroutine is not supported by the underlying transport provider.
TNOUDERR No unit data error indication currently exists on the specified transport endpoint.
TPROTO This error indicates that a communication problem has been detected between the X/Open Transport Interface and the transport provider for which there is no other suitable X/Open Transport Interface (t_errno).
TSYSERR A system error has occurred during execution of this subroutine.

Related Information

The t_rcvudata subroutine, t_sndudata subroutine.


[ Previous | Next | Contents | Glossary | Home | Search ]