Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ t_getstate(3N) — UnixWare 2.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

t_getinfo(3N)

t_open(3N)






       t_getstate(3N)                                        t_getstate(3N)


       NAME
             t_getstate - get the current state

       SYNOPSIS
             cc [options] file -lnsl
             #include <xti.h>
             int t_getstate(int fd);

          Parameters
             fd    the file descriptor for the transport endpoint
                   associated with the current state.

       DESCRIPTION
             This function is an TLI/XTI local management routine used to
             return the current state of the provider associated with the
             transport endpoint specified by fd.

             TLI/XTI states are changed by user events that reflect the
             success or failure of calls to the various TLI/XTI functions.
             Because fewer TLI/XTI user events occur over connectionless
             services, there are fewer TLI/XTI states than for connection-
             mode services.

             The current state may be one of the following:

             T_UNBND        unbound

             T_IDLE         idle

             T_OUTCON       outgoing connection pending (connection mode
                            only)

             T_INCON        incoming connection pending (connection mode
                            only)

             T_DATAXFER     data transfer (connection mode only)

             T_OUTREL       outgoing orderly release (waiting for an
                            orderly release indication) (connection mode
                            only)

             T_INREL        incoming orderly release (waiting for an
                            orderly release request) (connection mode only)





                           Copyright 1994 Novell, Inc.               Page 1













      t_getstate(3N)                                        t_getstate(3N)


         Return Values
            t_getstate returns the current state on successful completion
            and -1 on failure and t_errno is set to indicate the error.

         Errors
            On failure, t_errno may be set to one of the following:

            TBADF          The specified file descriptor does not refer to
                           a transport endpoint.

            TSTATECHNG     The transport provider is undergoing a state
                           change.

            TSYSERR        A system error has occurred during execution of
                           this function.

            TPROTO         A communication problem has been detected with
                           the transport provider and there is no other
                           value of t_errno to describe the error
                           condition.

         State Transitions
            t_getstate  may be issued from any valid state except T_UNINIT
            and has no effect on the state.

         Files
            /usr/lib/libxti.so       X/Open Transport Interface Library
                                     (shared object)
            /usr/lib/libnsl.so       Network Services Library (shared
                                     object)

      USAGE
            The t_getstate function is applicable to both connection-mode
            and connectionless transport services. The user events that
            may cause a change of state include the following:

            T_OPEN         successful return of t_open

            T_BIND         successful return of t_bind

            T_OPTMGMT      successful return of t_optmgmt

            T_UNBIND       successful return of t_unbind





                          Copyright 1994 Novell, Inc.               Page 2













       t_getstate(3N)                                        t_getstate(3N)


             T_CLOSE        successful return of t_close

             T_SNDUDATA     successful return of t_optmgmt

             T_RCVUDATA     successful return of t_optmgmt

             T_RCVUDERR     successful return of t_optmgmt

             T_CONNECT1     successful return of t_connect (synchronous)

             T_CONNECT2     error on t_connect

             T_RCVCONNECT   successful return of t_rcvconnect

             T_LISTN        successful return of t_listen

             T_ACCEPT1      successful return of t_accept (fd=resfd)

             T_ACCEPT2      successful return of t_accept (fd!=resfd)

             T_ACCEPT3      successful return of t_accept (ocnt>1)

             T_SND          successful return of t_snd

             T_RCV          successful return of t_rcv

             T_SNDDIS1      successful return of t_snddis (ocnt<=1)

             T_SNDDIS2      successful return of t_snddis (ocnt>1)

             T_RCVDIS1      successful return of t_rcvdis (ocnt<=0)

             T_RCVDIS2      successful return of t_rcvdis (ocnt=0)

             T_RCVDIS3      successful return of t_rcvdis (ocnt>1)

             T_SNDREL       successful return of t_sndrel

             T_RCVREL       successful return of t_rcvrel

             T_PASSCON      receive a passed connection

          Warnings
             If the provider is undergoing a state transition when
             t_getstate is called, the function will fail.



                           Copyright 1994 Novell, Inc.               Page 3













      t_getstate(3N)                                        t_getstate(3N)


      REFERENCES
            t_getinfo(3N), t_open(3N)














































                          Copyright 1994 Novell, Inc.               Page 4








Typewritten Software • bear@typewritten.org • Edmonds, WA 98026