Ends interaction with a host application.
HCON Library
C (libg3270.a)
Pascal (libg3270p.a)
FORTRAN (libg3270f.a)
function g32deal (var as : g32_api) : integer; external;
The g32_dealloc function ends interaction with the operating system application and the host application. The function releases control of the session.
HCON application programs using the Pascal language interface must include and link both the C and Pascal libraries. Application programs using the FORTRAN language for the HCON API must include and link both the C and FORTRAN libraries.
The g32_dealloc function is part of the Host Connection Program (HCON).
The g32_dealloc function requires one or more adapters used to connect to a host.
Item | Description |
---|---|
as | Specifies a pointer to a g32_api structure. Status is returned in this structure. |
Item | Description |
---|---|
as | Specifies the g32_api structure. |
Item | Description |
---|---|
AS | Specifies the g32_api equivalent structure as an array of integers. |
Item | Description |
---|---|
0 | Indicates successful completion. |
-1 | Indicates an error has occurred.
|
The following example illustrates the use of the g32_dealloc function in C language:
#include <g32_api.h> /* API include file */
main ()
{
struct g32_api *as, asx; /* asx is statically defined */
int session_mode = MODE_API; /* api session mode. Other
modes are MODE_API_T */
char appl_name [20]; /* name of the application to
run on the host */
int return; /* return code */
.
.
.
strcpy (appl_name, "APITESTN"); /* name of host application */
return = g32_alloc(as, appl_name, session_mode);
.
.
.
return = g32_dealloc(as);
.
.
.