*copyc OSD$DEFAULT_PRAGMATS
?? NEWTITLE := 'NOS/VE : Interactive Facility' ??
?? NEWTITLE := '  [XDCL] iip$report_unhandled_data_msg' ??
MODULE iim$report_unhandled_data_msg;

{ Global External System Procedures Declarations

{ Turn off the listing of pmxlogj and osdstat.

?? PUSH (LISTEXT := ON) ??
*copyc PMP$LOG
*copyc OST$STATUS
?? POP ??


{ Global Interactive Type Declarations

{ Turn off the listing of ifd180 and ifdnam.

?? PUSH (LISTEXT := ON) ??
*copyc IFV$MODULE_FOR_C180
*copyc iit$application_names_messages
?? POP ??

?? TITLE := 'PROCEDURE [XDCL] iip$report_unhandled_data_msg', EJECT ??

{  PURPOSE:
{    The purpose of this procedure is to report on an upline data message
{    which has not been handled for some reason or other.
{

  PROCEDURE [XDCL] iip$report_unhandled_data_msg (VAR msg:
    iit$input_data_message);

    CONST
      legend_1 = 'Unhandled input data message:',
      legend_2 = 'ABT:  ; ADR:     ; ABN:      ;ACT:   IBU:      ;',
      legend_3 = 'XPT:      ;CAN:      ;PEF:      ;TLC:     ;';

    VAR
      line: string (60),
      status: ost$status,
      i: integer;

{ Log the kind of error report that is to follow.

    pmp$log (legend_1, status);

    line (1, 49) := legend_2;
    STRINGREP (line (6, 1), i, msg.header.block_type);
    STRINGREP (line (14, 4), i, msg.header.connection_number);
    STRINGREP (line (24, 5), i, msg.header.block_number);
    STRINGREP (line (36, 2), i, msg.header.character_type);
    STRINGREP (line (44, 5), i, msg.header.undeliverable);

    pmp$log (line (1, 49), status);

{ Log the transparent mode, cancel input, parity error and text length.
    line (1, 43) := legend_3;
    STRINGREP (line (6, 5), i, msg.header.transparent);
    STRINGREP (line (17, 5), i, msg.header.cancel);
    STRINGREP (line (28, 5), i, msg.header.parity_error);
    STRINGREP (line (39, 4), i, msg.header.text_length);

    pmp$log (line (1, 43), status);

  PROCEND iip$report_unhandled_data_msg;

MODEND iim$report_unhandled_data_msg;
