OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-27
Example 1 in C—Updating a Remote File (in Nowait
Mode)
583 {
584
585 /*******************************************************************/
586 /* The tag value represents the type of FTM request or response */
587 /* procedure associated with this I/O completion. The tag value */
588 /* comes from the MFM_AWAITIOX_ call. */
589 /*******************************************************************/
590
591 switch (tag)
592 {
593
594 case INITIALIZE_TAG:
595 /****************************************************************/
596 /* After FTM_INITIALIZE_REQ_ completes, issue an event- */
597 /* receive call to retrieve the initialize confirm. All subse- */
598 /* quent event-receive calls are issued from the ftam_event_rcvd*/
599 /* procedure after each event-receive request completes. */
600 /****************************************************************/
601
602 status = APS_EVENT_RECEIVE_ ( cepi
603 , /* WAIT_FOREVER */
604 , (long) EVENTREC_TAG );
605
606 check_status ();
607 break;
608
609 case FILEOPEN_TAG:
610 case TRANSFEREND_TAG:
611 case FILECLOSE_TAG:
612 case TERMINATE_TAG:
613 /****************************************************************/
614 /* These requests do not require any action. The */
615 /* ftam_event_rcvd procedure has already issued an event- */
616 /* receive call. */
617 /****************************************************************/
618
619 break;
620
621 case WRITE_TAG: