OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-96
Example 1 in TAL—Updating a Remote File (in
Nowait Mode)
1558 , error_subcode
1559 , ! service_id !
1560 , ! diagnostic_buffer !
1561 , original_error_info );
1562
1563 CALL check_error;
1564
1565 !----------------------------------------------------------------!
1566 ! Display the status code. !
1567 !----------------------------------------------------------------!
1568
1569 tempbuf ':=' "STATUS # " -> @text_ptr;
1570 IF (status < 0) THEN
1571 BEGIN
1572 status := -status;
1573 text_ptr ':=' "-" -> @text_ptr;
1574 END;
1575 @text_ptr := @text_ptr + DNUMOUT ( text_ptr
1576 , $DBL ( status )
1577 , BASE );
1578 text_len := @text_ptr - @tempbuf;
1579 CALL WRITE ( termnum, outbuf, text_len );
1580
1581 !----------------------------------------------------------------!
1582 ! Display the error code and subcode. !
1583 !----------------------------------------------------------------!
1584
1585 tempbuf ':=' "ERROR CODE # " -> @text_ptr;
1586 IF ( error_code < 0) THEN
1587 BEGIN
1588 error_code := -error_code;
1589 text_ptr ':=' "-" -> @text_ptr;
1590 END;
1591 @text_ptr := @text_ptr + DNUMOUT ( text_ptr
1592 , $DBL ( error_code )
1593 , BASE );
1594 text_len := @text_ptr - @tempbuf;
1595 CALL WRITE ( termnum, outbuf, text_len );
1596