OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-25
Example 1 in C—Updating a Remote File (in Nowait
Mode)
505 FILEINFO ( local_filenum, &error );
506 printf ("Local file error %d\n", error);
507 APS_DISCARD_ ( cepi );
508 exit (EXIT_SUCCESS);
509 }
510
511 /****************************************************************/
512 /* Verify that the local I/O completion was for a file read. */
513 /****************************************************************/
514
515 if ( tag == READ_TAG )
516 {
517 /*************************************************************/
518 /* Indicate that the local file read completed successfully */
519 /* and transfer the data that was read to the responder. */
520 /*************************************************************/
521
522 local_read_io_cmplt = TRUE;
523 data_transfer ();
524 }
525 else
526 {
527 printf ("Invalid TAG\n");
528 APS_DISCARD_ ( cepi );
529 exit (EXIT_FAILURE);
530 }
531 }
532 } /* End of WHILE loop */
533
534 /**********************************************************************/
535 /* Discard the API context information for the association. */
536 /**********************************************************************/
537
538 APS_DISCARD_ ( cepi );
539
540 /**********************************************************************/
541 /* Close the local file that was opened for transfer. */
542 /**********************************************************************/
543