OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-140
Example 2 in C—Moving a File Between Two
Remote Systems (in Wait Mode)
1324 if ( file_attr.zaccesscntrlattrispresent == ZAPS_VAL_PRESENT )
1325 {
1326 change_attr.zaccesscntrlispresent = ZAPS_VAL_PRESENT;
1327 change_attr.zaccesscntrl.zid = ZFTM_VAL_ATTR_ISPRESENT;
1328 change_attr.zaccesscntrl.zinsertispresent = ZAPS_VAL_PRESENT;
1329 change_attr.zaccesscntrl.zinsertvalues = file_attr.
1330 zaccesscntrlattr.zaccesscntrl;
1331 }
1332 else
1333 {
1334 change_attr.zaccesscntrlispresent = ZAPS_VAL_ABSENT;
1335 }
1336
1337 /******************************************************************/
1338 /* Initialize the threshold for the begin-group request so */
1339 /* that all three services (close, change attributes, and */
1340 /* deselect) must be successful for the group to succeed. */
1341 /******************************************************************/
1342
1343 threshold = 3;
1344 status = FTM_BEGIN_GROUP_REQ_ ( dst_cepi
1345 , threshold );
1346 check_status ( dst_cepi );
1347
1348 status = FTM_CLOSE_REQ_ ( dst_cepi );
1349 check_status ( dst_cepi );
1350
1351 status = FTM_CHANGE_ATTRIB_REQ_ ( dst_cepi
1352 , (int *) &change_attr );
1353 check_status ( dst_cepi );
1354
1355 status = FTM_DESELECT_REQ_ ( dst_cepi );
1356 check_status ( dst_cepi );
1357
1358 status = FTM_END_GROUP_REQ_ ( dst_cepi );
1359 check_status ( dst_cepi );
1360
1361 /*******************************************************************/
1362 /* Call the following procedures to process the confirms returned */