📄 t_look.3.man
字号:
'\" rtp.\" -*- nroff -*- vim: ft=nroff noautoindent nocindent nosmartindent.\".\" @(#) t_look.3.man,v 0.9.2.2 2004/05/16 02:35:36 brian Exp.\".\" =========================================================================.\".\" Copyright (C) 2001-2004 OpenSS7 Corporation <www.openss7.com>.\".\" All Rights Reserved..\".\" Permission is granted to make and distribute verbatim copies of this.\" manual provided the copyright notice and this permission notice are.\" preserved on all copies..\".\" Permission is granted to copy and distribute modified versions of this.\" manual under the conditions for verbatim copying, provided that the.\" entire resulting derived work is distributed under the terms of a.\" permission notice identical to this one.\" .\" Since the Linux kernel and libraries are constantly changing, this.\" manual page may be incorrect or out-of-date. The author(s) assume no.\" responsibility for errors or omissions, or for damages resulting from.\" the use of the information contained herein. The author(s) may not.\" have taken the same level of care in the production of this manual,.\" which is licensed free of charge, as they might when working.\" professionally..\" .\" Formatted or processed versions of this manual, if unaccompanied by.\" the source, must acknowledge the copyright and authors of this work..\".\" -------------------------------------------------------------------------.\".\" U.S. GOVERNMENT RESTRICTED RIGHTS. If you are licensing this Software.\" on behalf of the U.S. Government ("Government"), the following.\" provisions apply to you. If the Software is supplied by the Department.\" of Defense ("DoD"), it is classified as "Commercial Computer Software".\" under paragraph 252.227-7014 of the DoD Supplement to the Federal.\" Acquisition Regulations ("DFARS") (or any successor regulations) and the.\" Government is acquiring only the license rights granted herein (the.\" license rights customarily provided to non-Government users). If the.\" Software is supplied to any unit or agency of the Government other than.\" DoD, it is classified as "Restricted Computer Software" and the.\" Government's rights in the Software are defined in paragraph 52.227-19.\" of the Federal Acquisition Regulations ("FAR") (or any success.\" regulations) or, in the cases of NASA, in paragraph 18.52.227-86 of the.\" NASA Supplement to the FAR (or any successor regulations)..\".\" =========================================================================.\" .\" Commercial licensing and support of this software is available from.\" OpenSS7 Corporation at a fee. See http://www.openss7.com/.\" .\" =========================================================================.\".\" Last Modified 2004/05/16 02:35:36 by brian.\".\" =========================================================================.so strxnet.macros.R1bracket-label "\fR[\fB" "\fR]" "\fR, \fB"no-default-databasedatabase strxnet.refsaccumulatemove-punctuationabbreviate Ajoin-authors ", " ", " " and "et-al " et al" 2 3abbreviate-label-ranges ".."sort-adjacent-labels.R2.\".\".\".\".TH T_LOOK 3 "2004/05/16 02:35:36" "strxnet-0_9_2-4" "OpenSS7 XTI/TLI Library".\".\".SH NAME.B t_look\- look for a transport event.\".\".SH SYNOPSIS.PP.B #include <xti.h>.HP 8.BI "int t_look(int " fd );.\".\".SH ARGUMENTS.PP.TP.I fdthe transport endpoint upon which to look for events..\".\".SH DESCRIPTION.PP.BR t_look ()looks for a pending asynchronous event on the local transport endpointspecified by.IR fd ..PP.I fdspecifies the local transport endpoint upon which to look for a pendingasynchronous event..\".\".SH CAVEATS.PPWhen an XTI/TLI library call is expecting a specific response from the transportservice provider, such as in.BR t_accept (3),.BR t_addleaf (3),.BR t_connect (3),.BR t_listen (3),.BR t_rcv (3),.BR t_rcvconnect (3),.BR t_rcvleafchange (3),.BR t_rcvrel (3),.BR t_rcvreldata (3),.BR t_rcvv (3),.BR t_rcvvudata (3),.BR t_removeleaf (3),.BR t_snd (3),.BR t_snddis (3),.BR t_sndrel (3),.BR t_sndreldata (3),.BR t_sndudata (3),.BR t_sndv (3),.BR t_sndvudata (3),and.BR t_unbind (3),an asynchronous event is received other than the expected event, the abovecalls will fail, return -1 and set.IR t_errno (3)to.BR TLOOK .When such a failure occurs,.BR t_look ()can be used to determine which asynchronous event occured and determine thenext course of action..PPAlso,.BR t_look ()can be used to determine which event is pending without previoulsy calling oneof the XTI/TLI library calls listed above. For example,.BR t_look ()can be called after a call to.BR poll (2)for a group of file descriptors to determine the event that has occured on thetransport endpoint. This is in fitting with the.BR poll (2)example listed in XNS 5.2..[xns.].PPThe following XTI/TLI library commands return.RB [ TLOOK ]when the listed asynchronous events have occured:.sp.TStab(:);lblssss.t_accept\fR(3):T_DISCONNECT, T_LISTENt_connect\fR(3):T_DISCONNECT, T_LISTENt_listen\fR(3):T_DISCONNECTt_rcv\fR(3):T_DISCONNECT, T_ORDRELt_rcvconnect\fR(3):T_DISCONNECTt_rcvrel\fR(3):T_DISCONNECTt_rcvreldata\fR(3):T_DISCONNECTt_rcvudata\fR(3):T_UDERRt_rcvv\fR(3):T_DISCONNECT, T_ORDRELt_rcvvudata\fR(3):T_UDERRt_snd\fR(3):T_DISCONNECT, T_ORDRELt_sndudata\fR(3):T_UDERRt_sndv\fR(3):T_DISCONNECT, T_ORDRELt_sndvudata\fR(3):T_UDERRt_unbind\fR(3):T_LISTEN, T_DATA, T_UDERRt_sndrel\fR(3):T_DISCONNECTt_sndreldata\fR(3):T_DISCONNECTt_snddis\fR(3):T_DISCONNECT.TE.\".\".SH "RETURN VALUE".PPUpon success,.BR t_look ()returns a positive integer reflecting the asynchronous event received and is one of thefollowing values:.TP.B T_LISTENconnection indication received..TP.B T_CONNECTconnection confirmation received..TP.B T_DATAnormal data received..TP.B T_EXDATAexpedited data received..TP.B T_DISCONNECTdisconnection received..TP.B T_UDERRdatagram error indication received..TP.B T_ORDRELorderly release indication received..TP.B T_GODATAsending normal data is again possible..TP.B T_GOEXDATAsending expedited data is again possible..PPUpon failure,.BR t_look ()returns -1 and sets.IR t_errno (3)to an appropriate error number..\".\".SH ERRORS.PPWhen.BR t_look ()fails, it returns -1 and sets.IR t_errno (3)to an appropriate error number as follows:.TP \w'[TNOTSUPPORT]\(em'u.RB [ TBADF ].I fdis invalid..TP.RB [ TPROTO ]A protocol error occured between the XTI/TLI library and the underlying transport provider..TP.RB [ TSYSERR ]A \fBLinux\fR system error occured and the \fBLinux\fR error number is set in.IR errno (3)..\".\".SH "SEE ALSO".PP.BR errno (3),.BR t_accept (3),.BR t_addleaf (3),.BR t_connect (3),.BR t_errno (3)..BR t_listen (3),.BR t_rcv (3),.BR t_rcvconnect (3),.BR t_rcvleafchange (3),.BR t_rcvrel (3),.BR t_rcvreldata (3),.BR t_rcvv (3),.BR t_rcvvudata (3),.BR t_removeleaf (3),.BR t_snd (3),.BR t_snddis (3),.BR t_sndrel (3),.BR t_sndreldata (3),.BR t_sndudata (3),.BR t_sndv (3),.BR t_sndvudata (3),.BR t_unbind (3)..\".\".SH "BUGS".PP.BR t_look ()has no known bugs..BR t_look ()has been tested for the described behavior using the.I /usr/bin/test-xnetconformance test program..\".\".SH "CONFORMING TO".PPXTI/TLI,.[XTI.]TPI,.[TPI Revision 2.0.0.]XPG5,XNS 5.2,.[xns.]SUSv2..[susv2.].\".\".[$LIST$.].T4
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -