*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> t_getprotaddr (3)              
Title
Content
Arch
Section
 

t_getprotaddr(3)

Contents


NAME    [Toc]    [Back]

       t_getprotaddr - Get the protocol address

SYNOPSIS    [Toc]    [Back]

       #include <xti.h>

       int t_getprotaddr(
               int fd,
               struct t_bind *boundaddr,
               struct t_bind *peeraddr );

LIBRARY    [Toc]    [Back]

       XTI Library (libxti.a)

STANDARDS    [Toc]    [Back]

       Interfaces  documented  on  this reference page conform to
       industry standards as follows:

       t_getprotaddr():  XNS4.0, XNS5.0

       Refer to the standards(5) reference page for more information
 about industry standards and associated tags.

PARAMETERS    [Toc]    [Back]

       The  following table summarizes the relevance of input and
       output parameters  before  and  after  t_getprotaddr()  is
       called:

       -----------------------------------------------
       Parameters            Before Call   After Call
       -----------------------------------------------
       fd                    y             n
       boundaddr->maxlen     y             n
       boundaddr->addr.len   n             y
       boundaddr->addr.buf   o             (o)
       boundaddr->qlen       n             n
       peeraddr->maxlen      y             n
       peeraddr->addr.len    n             y
       peeraddr->addr.buf    o             (o)
       peeraddr->qlen        n             n
       -----------------------------------------------

       Table  Notes: This is a meaningful parameter.  The content
       of the object pointed to by y is meaningful.   This  is  a
       meaningful  but  optional  parameter.   The content of the
       object pointed to by o is meaningful.  This is not a meaningful
 parameter.

       Specifies a file descriptor returned by the t_open() function
 that identifies the transport endpoint through  which
       data  is  sent.   Specifies the location to hold the local
       address, if any, currently bound to fd.  It  points  to  a
       structure  of  type t_bind, with the following fields: The
       maximum size of the address buffer.  Points to the  buffer
       where  the  address  is  to  be placed. In return, the buf
       field of boundaddr points to the address, if any, that  is
       currently  bound  to  fd.   Specifies  the  length  of the
       address.  If the transport  endpoint  is  in  the  T_UNBND
       state,  zero  is returned in the len field.  Specifies the
       location to hold the remote address, if any, that is  currently
  connected  to fd.  It points to a structure of the
       type t_bind, with the following fields: The  maximum  size
       of  the  address  buffer.   Points to the buffer where the
       address is to be placed. The buf field of peeraddr  points
       to the address, if any, currently connected to fd.  Specifies
 the length of the address. If the transport  endpoint
       is  not  in the T_DATAXFER state, zero is returned in this
       field.

DESCRIPTION    [Toc]    [Back]

       The t_getprotaddr() function returns local and remote protocol
  addresses  currently  associated with the transport
       endpoint specified by fd.

RETURN VALUES    [Toc]    [Back]

       Upon successful completion, a value of zero  is  returned.
       If the transport endpoint is in the T_UNBND state, zero is
       returned  in  the   len   field   of   boundaddr   (boundaddr->addr.len).


       If  the transport endpoint is not in the T_DATAXFER state,
       then zero is returned in the len field of peeraddr  (peeraddr->addr.len
 = 0). On failure, a value of -1 is returned
       and t_errno is set to indicate the error.

ERRORS    [Toc]    [Back]

       If the t_getprotaddr() function fails, t_errno may be  set
       to  one  of  the  following  values:  The  specified  file
       descriptor does note refer to a transport  endpoint.   The
       number   of  bytes  allocated  for  an  incoming  argument
       (maxlen) is greater than zero but not sufficient to  store
       the  value  of that argument.  A system error has occurred
       during execution of this function.  This  error  indicates
       that a communication problem has been detected between XTI
       and the transport provider for which  there  is  no  other
       suitable XTI(t_errno).

VALID STATES    [Toc]    [Back]

       The  t_getprotaddr()  function  can  be  called in all the
       transport provider states, except T_UNINIT.

SEE ALSO    [Toc]    [Back]

      
      
       Functions: t_bind(3)

       Standards: standards(5)

       Network Programmer's Guide



                                                 t_getprotaddr(3)
[ Back ]
 Similar pages
Name OS Title
arp IRIX Address Resolution Protocol
arp OpenBSD Address Resolution Protocol
arp Tru64 Address Resolution Protocol
arp FreeBSD Address Resolution Protocol
carp OpenBSD Common Address Redundancy Protocol
rarpd HP-UX Reverse Address Resolution Protocol daemon
bind FreeBSD assign a local protocol address to a socket
rarpc HP-UX Reverse Address Resolution Protocol client
getnameinfo Linux address-to-name translation in protocol-independent manner
arp Tru64 Displays and controls Address Resolution Protocol (ARP) tables
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service