sni_connect(3) CLIX sni_connect(3)
NAME
sni_connect - Connect to a server program
LIBRARY
INC Library (libinc.a)
SYNOPSIS
char *sni_connect(
long *sd ,
char *node ,
unsigned short sernum ,
char *server );
PARAMETERS
sd A pointer to a long integer representing a network interface
descriptor
node A pointer to a node specifier for the remote system
sernum The number of the server for which the connection is desired
server A pointer to the name of an executable file
DESCRIPTION
The sni_connect() function creates a requester/server connection and
assigns a Simple Network Interface (SNI) descriptor to the connection.
The call completes when the requester and server connect or an error
occurs.
Before sni_connect() returns, the server must invoke the sni_accept()
function.
On successful completion, the long to which sd points is assigned an
identifier for the particular connection, called an SNI descriptor.
The node parameter points to a node specifier for the remote system.
Depending on the system, node has one of the following formats:
⊕ nodename
⊕ nodename.username. (SNI prompts for password)
⊕ nodename.username.passwd
⊕ network-address
2/94 - Intergraph Corporation 1
sni_connect(3) CLIX sni_connect(3)
⊕ network-address.username. (SNI prompts for password)
⊕ network-address.username.passwd
the sernum parameter is the number of the server for which the connection
is desired. The file /usr/ip32/inc/server.dat contains the available
servers and server numbers for the system. If sernum is zero, server
should point to the name of the executable file to be used on the remote
system as a server. If sernum is not zero, server should be zero.
FILES
/usr/ip32/inc/server.dat Server information file
/usr/lib/nodes/heard/* Nodename clearinghouse files
NOTES
The sni_connect() function is only called in the requester program.
CAUTIONS
A nodename in the node argument may only be specified if that nodename is
in the local Intergraph clearinghouse.
RETURN VALUES
Upon successful completion, a null pointer is returned. Otherwise, a
pointer to an error message is returned.
RELATED INFORMATION
Commands: xns_listener(8)
Functions: sni_accept(3), sni_close(3)
Files: server.dat(4)
2 Intergraph Corporation - 2/94