OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-13
Example 1 in C—Updating a Remote File (in Nowait
Mode)
37 /* response procedures, as well as the */
38 /* I/O completions */
39 /* */
40 /* check_error A procedure that checks for errors */
41 /* returned by FTM indication and */
42 /* confirm procedures */
43 /* */
44 /* check_action_diag A procedure that checks the action */
45 /* result and diagnostic messages */
46 /* returned by an FTM procedure */
47 /* */
48 /* bad_state A procedure that handles an invalid */
49 /* FTM state result */
50 /* */
51 /* FTM requests and responses return a status value on both */
52 /* the procedure call and the I/O completion. The check_status */
53 /* procedure checks the results of the operation. The FTM */
54 /* indication and confirm procedures return an error value and */
55 /* do not have I/O completions. The check_error procedure checks */
56 /* the return value. */
57 /* */
58 /***********************************************************************/
59 /* */
60 /* NOTE : Before attempting to run this program, make sure: */
61 /* */
62 /* a) the environmental variables are set correctly */
63 /* b) the local file contains at least five records */
64 /* c) the local file record length is less than or */
65 /* equal to 132 bytes */
66 /* d) the required parameters (currently using defaults) */
67 /* in the FTM_INITIALIZE_REQ_ call are set correctly */
68 /* */
69 /***********************************************************************/
70
71 #pragma NOLIST
72 #include <stdioh>
73 #include <stdlibh>
74 #include <stringh>
75 #include <talh>