home *** CD-ROM | disk | FTP | other *** search
/ kermit.columbia.edu / kermit.columbia.edu.tar / kermit.columbia.edu / test / pdp11 / krter3.mac < prev    next >
Text File  |  1996-10-17  |  4KB  |  139 lines

  1.     .title    rmser3    overlay 3 of 3 for rms error text
  2.     .ident    /V04.64/
  3.  
  4. ; /E64/    10-May-96  John Santos
  5. ;
  6. ;    From K11ER3.MAC
  7.  
  8.     .psect
  9.  
  10.  
  11.  
  12.     .macro    save    list
  13.     .if b , <list>
  14.     .ift
  15.      save    <r0,r1,r2,r3,r4,r5>
  16.     .iff
  17.     .irp    x,<list>
  18.      mov    x,-(sp)
  19.         .endr
  20.     .endc
  21.     .endm    save
  22.  
  23.  
  24.     .macro    unsave    list
  25.     .if b , <list>
  26.     .ift
  27.     unsave    <r5,r4,r3,r2,r1,r0>
  28.     .iff
  29.     .irp    x,<list>
  30.      mov    (sp)+,x
  31.         .endr
  32.     .endc
  33.     .endm    unsave
  34.  
  35.  
  36.  
  37. rmser3::save    <r0,r1,r2>        ; be nice to our caller
  38.     mov    4(r5)    ,r1        ; return buffer address
  39.     mov    r1    ,r2        ; save buffer address
  40.     clrb    (r1)+            ; make first char .asciz
  41.     mov    #77    ,r0        ; clear it out first
  42. 10$:    movb    #40    ,(r1)+        ; fill rest of buffer with spaces
  43.     sob    r0    ,10$        ; next please
  44.     mov    #dsp    ,r0        ; get the index table for errors
  45. 20$:    tst    @r0            ; hit the end yet ?
  46.     beq    100$            ; yes, exit with no text
  47.     cmp    @2(r5)    ,@r0        ; type indexentry = record
  48.     beq    30$            ;       errnum: integer
  49.     cmp    (r0)+    ,(r0)+        ;    errtxt: textaddress
  50.     br    20$            ;      end ;
  51.  
  52. 30$:    mov    2(r0)    ,r0        ; get the error text address
  53.     mov    #77    ,r1        ; maxlength of 77 (8) bytes
  54. 40$:    movb    (r0)+    ,(r2)+        ; copy until 63 characters or a
  55.     beq    50$            ; null byte is found
  56.     sob    r1    ,40$        ; next please
  57. 50$:    clrb    @r2            ; insure .asciz for output text
  58.  
  59. 100$:    unsave    <r2,r1,r0>        ; pop our registers and exit
  60.     return
  61.  
  62.  
  63.  
  64.  
  65.     .psect    dsp    ,ro,d,lcl,rel,con
  66. dsp:
  67.     .psect    msgtxt    ,ro,d,lcl,rel,con
  68.     .macro    $ioer$    nam,code,txt
  69.  
  70.     .psect    msgtxt
  71.     $$ = .
  72.     .ascii    #nam#
  73.     .ascii    #-#            ;/*60*/
  74.     .asciz    #txt#
  75.     .psect    dsp
  76.     .word    code,$$
  77.     nam    =    code
  78.     .psect
  79.     .endm
  80.  
  81.  
  82.  
  83.  
  84. $IOER$    ER$NPK,-1184.,<Indexed file-no primary key defined>
  85. $IOER$    ER$OPN,-1200.,<RSTS/E open function failed (STV=SYS err code)>
  86. $IOER$    ER$ORD,-1216.,<XAB'S not in correct order>
  87. $IOER$    ER$ORG,-1232.,<Invalid file organization value>
  88. $IOER$    ER$PLG,-1248.,<Error in file's prologue (Reconstruct file)>
  89. $IOER$    ER$PLV,-1256.,<File prologue version level unsupported>
  90. $IOER$    ER$POS,-1264.,<"POS" field invalid (POS gt MRS, STV=@XAB)>
  91. $IOER$    ER$PRM,-1280.,<Bad file date field retrieved (STV=@XAB)>
  92. $IOER$    ER$PRV,-1296.,<Privilege violation (OS denies access)>
  93. $IOER$    ER$RAB,-1312.,<Not a valid RAB>
  94. $IOER$    ER$RAC,-1328.,<Illegal RAC value>
  95. $IOER$    ER$RAT,-1344.,<Illegal record attributes>
  96. $IOER$    ER$RBF,-1360.,<Invalid record buffer addr>
  97. $IOER$    ER$RER,-1376.,<File read error (STV=SYS err code)>
  98. $IOER$    ER$REX,-1392.,<Record already exists>
  99. $IOER$    ER$RFA,-1408.,<Bad RFA value>
  100. $IOER$    ER$RFM,-1424.,<Invalid record format>
  101. $IOER$    ER$RLK,-1440.,<Target bucket locked by another accessor>
  102. $IOER$    ER$RMV,-1456.,<RSX-F11ACP remove function failed (STV=SYS err code)>
  103. $IOER$    ER$RNF,-1472.,<Record not found (STV=0/ER$IDX)>
  104. $IOER$    ER$RNL,-1488.,<Record not locked>
  105. $IOER$    ER$ROP,-1504.,<Invalid record options>
  106. $IOER$    ER$RPL,-1520.,<Error while reading prologue (STV=SYS err code)>
  107. $IOER$    ER$RRV,-1536.,<Invalid RRV record encountered>
  108. $IOER$    ER$RSA,-1552.,<This error code no longer used>
  109. $IOER$    ER$RSL,-1556.,<No resultant string in resultant string area>
  110. $IOER$    ER$RSS,-1560.,<Invalid resultant string size>
  111. $IOER$    ER$RST,-1564.,<Invalid resultant string address>
  112. $IOER$    ER$RSZ,-1568.,<Bad record size>
  113. $IOER$    ER$RTB,-1584.,<Record too big for user's buffer (STV=Actual rec size)>
  114. $IOER$    ER$RVU,-1592.,<RRV update error on insert>
  115. $IOER$    ER$SEQ,-1600.,<Primary key out of sequence (RAC=RB$SEQ for $PUT)>
  116. $IOER$    ER$SHR,-1616.,<Unrecognizable value in FAB SHR field>
  117. $IOER$    ER$SIZ,-1632.,<"SIZ" field invalid (STV=@XAB)>
  118. $IOER$    ER$STK,-1648.,<This error code no longer used>
  119. $IOER$    ER$SUP,-1656.,<Operation unsupported over network>
  120. $IOER$    ER$SYS,-1664.,<System directive error (STV=SYS err code)>
  121. $IOER$    ER$TRE,-1680.,<Index tree error>
  122. $IOER$    ER$TYP,-1696.,<Error in file type extension>
  123. $IOER$    ER$UBF,-1712.,<Invalid user buffer addr>
  124. $IOER$    ER$UIN,-1720.,<FAL rejected some field (STV tells which)>
  125. $IOER$    ER$USZ,-1728.,<Invalid user buffer size (USZ=0)>
  126. $IOER$    ER$VER,-1744.,<Error in version number>
  127. $IOER$    ER$VOL,-1760.,<Invalid volume number (STV=@XAB)>
  128. $IOER$    ER$WCD,-1768.,<Wild card encountered during FNA/DNA string parse>
  129. $IOER$    ER$WER,-1776.,<File write error (STV=SYS err code)>
  130. $IOER$    ER$WLK,-1784.,<Device is write-locked>
  131. $IOER$    ER$WPL,-1792.,<Error while writing prologue (STV=SYS err code)>
  132. $IOER$    ER$XAB,-1808.,<Not a valid XAB (@XAB=odd, STV=@XAB)>
  133. $IOER$    ER$XTR,-1824.,<Extraneous field detected during parse>
  134.  
  135.     .psect    dsp
  136.     .word    0,0            ; mark end of text
  137.  
  138.     .end
  139.