Terminates the X.25 API for a specified X.25 port.
X.25 Communications Library (libx25s.a)
int x25_term(link_name) struct cb_link_name_struct *link_name;
The x25_term subroutine terminates communication with the X.25 device driver to stop X.25 communications with the X.25 port named by the link_name subroutine. If this is the last X.25 port open for this process, X.25 resources are freed.
The x25_term subroutine clears any virtual circuits still being used by the application. However, it is recommended that you clear virtual circuits in an orderly manner before invoking the x25_term subroutine.
link_name | Contains the pointer to the cb_link_name_struct structure, which gives the name of the X.25 port. |
If successful, the x25_term subroutine returns a value of 0. If an error occurs, the x25_term subroutine returns a value of -1 and sets the x25_errno global variable to one of the error codes shown below.
On failure, the x25_errno global variable is set to one of the following:
The example program svcxmit illustrates code statements that terminates an API.
This subroutine is part of X.25 Application in Base Operating System (BOS) Extensions 2.
The x25_init subroutine.
Processing Calls with the X.25 API, Using the X.25 Structures and Flags, in AIX Version 4.3 Communications Programming Concepts.