OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-155
Example 2 in C—Moving a File Between Two
Remote Systems (in Wait Mode)
1909 {
1910 status = FTM_U_ABORT_REQ_ ( src_cepi
1911 , /* action_result */
1912 , /* diagnostics */ );
1913 check_status ( src_cepi );
1914 }
1915 if ( dst_con_established )
1916 {
1917 status = FTM_U_ABORT_REQ_ ( dst_cepi
1918 , /* action_result */
1919 , /* diagnostics */ );
1920 check_status ( dst_cepi );
1921 }
1922 }
1923
1924 /*******************************************************************/
1925 /* Verify that a CEPI exists, and if it does, discard it. */
1926 /*******************************************************************/
1927
1928 if ( src_cepi != NOCEPI )
1929 {
1930 status = APS_DISCARD_ ( src_cepi );
1931 }
1932
1933 if ( dst_cepi != NOCEPI )
1934 {
1935 status = APS_DISCARD_ ( dst_cepi );
1936 }
1937
1938 /*******************************************************************/
1939 /* Display a message to the terminal and exit the program. */
1940 /*******************************************************************/
1941
1942 printf ( "Unexpected event received\n");
1943 printf ( "Associations discarded\n");
1944
1945 exit (EXIT_SUCCESS);
1946
1947 } /*** bad_event ***/