+1,1
         PCC      0
         SYSTEM   SIG7
+28,28
         DEF      TVLPTSZ,PGINCRM,THRESH
         DEF      NOTAPE,OPSMSG,REGS
+39,39
         REF      KEYIN,PURADJ,J:JIT
+42
         REF      SL:THRS,SEL:BUF,PURDYN
         REF      SEL:MT
+43,43
         PCC      0
         PAGE
+104,105
         GEN,16,16  35,0
         RES      35
+105
         TEXT     ' REGISTERS: '
REGS     RES      16                BUFFER FOR TRAP OR SNAP REGS
+123,124
DEFAULT  EQU      $
         PZE      10                INITIAL 5K BUFFER
PGINCRM  EQU      $
         PZE      60                30K INCREMENT FOR BUFFER
+136,137
PAGE     PZE
PAGES    PZE
+139,142
+169
UBKUPMSG TEXTC    'USER-INITIATED BACKUP REQUESTED'
FILLABRT TEXTC    'FILL GHOST ABORTING'
ERROR    TEXTC    'ERROR SNAP'
+182,182
ORGTBL   TEXT     ' SYN'
+194,197
ACCTMBS  DATA     BA(F:EI+X'20')
         GEN,8,24 8,BA(PBUFFER)+2
+225
THRESH   DATA     SL:THRS
         RES      5                 ADD A 5 WORD PATCH TO BUFFER
+258,258
+341,344
NXFIL    RES      9+3+3             NAME, ACCOUNT, PASSWORD
+367
OPNBREC  GEN,8,24 X'14',F:BREC
         DATA     X'C7000000'
         DATA     BSR1
         DATA     BSR1
         DATA     2,2,4             KEYED,DIRECT,INOUT
         SPACE    2
DESELKEY GEN,8,24 X'0D',F:BREC
         PZE      *0
         DATA     SELKEY
         SPACE    2
+459,466
+532,532
         DATA     HEADER,1
+536
         SPACE    2
EOINOUT  GEN,8,24 X'14',F:EO
         DATA     X'C1000400'
         DATA     SQABN,SQABN
         SPACE    2
OPNDEVTP GEN,8,24 X'14',F:EO
         DATA     X'C0040000'
         DATA     BSR1,BSR1
         DATA     'D4E3'            'MT' DEVICE OPEN
+584,587
         LW,R6    LASTRUN
         BNEZ     BB4
BB3      EQU      $
         LW,R7    NSCHED
         BEZ      NOSCHD
         B        FIND:NXT
BB4      EQU      $
         CI,R6    3                 IGNORE RESTART OF ANYTHING BUT BACKUPS.
         BLE      CRASH             CRASHED DURING BACKUP - CONTINUE
         STW,R0   LASTRUN
         BAL,R5   WRT:SAV
         B        BB3
         PAGE
+592
CRASH    EQU      $
+596,599
         BAL,SR3  NOTAPE            SET UP NEW SERIAL NUMBERS
         BAL,SR2  OPNFIRST
         STW,R1   NOTAPFG
+669,669
+904,904
         PAGE
+972,987
+1033,1033
         CI,R8    X'20'             IS TAPE OPEN?
+1038,1038
         CI,R8    X'20'             IS FILE OPEN?
+1045,1045
         CI,R6    6                 IS THIS A SELECTIVE FILL?
         BNE      NO:FILL           NO
         LH,R8    F:BREC
         CI,R8    X'20'
         BANZ     SEL:MT
         CAL1,1   OPNBREC
         B        SEL:MT
+1070
         STW,R0   SUSPNDED
         STW,R0   SUSPACCT
         STW,R0   SUSPACCT+1
+1103
         LCI      0                 SAVE REGS FOR SNAPPER
         STM,R0   REGS
+1105,1105
         LI,R5    FILLABRT
         CAL1,2   TYPE              SHOT DOWN IN FLAMES MESSAGE
         CAL1,9   SUPER:CLOSE       PRINT
         CAL1,9   1                 EXIT NORMALLY
+1106
*        BAL,R3   SNAPPER
*
*        INPUT:   ALL REGISTERS SHOULD BE STORED INTO 'REGS' BUFFER
*                 WITH A STM,R0 REGS INSTRUCTION.  SNAPPER WILL LOAD
*                 THOSE REGISTERS UPON EXIT.
*        OUTPUT:  A SNAP OF APPROPRIATE FILL DATA IS PRINTED
*        USES:    NONE
*
+1108,1119
         STW,R3   SNAPEXIT
         LW,D4    R3                HAVE CALLER IN REGISTERS
         LI,R4    X'A000'
         LI,R5    FILL
         LI,R6    FDATXT
         BAL,R3   SNAPSUB1
         LI,R4    J:JIT
         LI,R5    1
         LI,R6    JITXT
         BAL,R3   SNAPSUB
         LW,R4    PAGE
         LW,R5    PAGES
         BEZ      SNAPPER1
         LI,R6    INCTXT
         BAL,R3   SNAPSUB
SNAPPER1 EQU      $
         LW,R4    BUF
         LH,R5    NMPG
         BEZ      SNAPPER2
         LI,R6    BUFTXT
         BAL,R3   SNAPSUB
SNAPPER2 EQU      $
         LW,R4    SEL:BUF
         BEZ      SNAPPER3
         LI,R5    1
         LI,R6    SELTXT
         BAL,R3   SNAPSUB
SNAPPER3 EQU      $
         LW,R4    PURDYN
         BEZ      SNAPPER4
         LI,R5    4
         LI,R6    PURTXT
         BAL,R3   SNAPSUB
SNAPPER4 EQU      $
         LI,R5    ERROR             TYPE ERROR MESSAGE ON OC
         CAL1,2   TYPE
         LCI      0
         LM,R0    REGS              RESTORE REGS TO POINT PRECEEDING CALL
         B        *SNAPEXIT
*
FDATXT   TEXT     'FILLDATA'
INCTXT   TEXT     'INC BUFF'
BUFTXT   TEXT     'BUFFER'
JITXT    TEXT     'FILL JIT'
SELTXT   TEXT     'SELFILL '
PURTXT   TEXT     'PURGBUFF'
*
SNAPSUB  EQU      $
         SLS,R5   9
         AW,R5    R4
         AI,R5    -1
SNAPSUB1 EQU      $
         LCI      2
         LM,R6    *R6
         STM,R6   SNAPTXT
         CAL1,3   SNAP
*
         USECT    DATA
SNAP     PZE
         PZE      *R4
         PZE      *R5
SNAPTXT  RES      2
         NOP
         B        0,R3
*
SNAPEXIT RES      1
         USECT    PURE
+1433,1433
         LI,R7    MVENT
         B        MESSINIT
+1457,1457        LLF               #21643     10/18/74
         BEZ      CLS:B
+1478,1479
         LI,R7    MVENT
         MTW,0    NOTAPFG           IS A TAPE ALREADY MOUNTED?
         BNEZ     MESSINIT          YES, SKIP OPERATOR MESSAGE.
         LI,R5    UBKUPMSG
         CAL1,2   TYPE              TELL OPERATOR WHAT'S UP
         MTW,0    SQMOUNT           ARE USER BACKUP TAPES LEFT MOUNTED?
         BNEZ     MESSINIT          YES, PROCEED NORMALLY
+1483,1488
         LW,R6    LASTREEL
         XW,R6    SQREEL            SAVE CURRENT LASTREEL IN SQREEL
         BEZ      MESSINIT          THERE IS NO CURRENT SQREEL
         STW,R6   SQREELX
+1499    LLF      #12231            10/18/74
OPENSQ   EQU      $
         CAL1,1   EOINOUT           OPEN SQ TAPE INOUT
         STW,R1   NOTAPFG
         LB,R5    LBLORG,R1         GET TYPE OF TAPE
         CI,R3    3                 IS IT A SQUIRREL TYPE?
         BE       OPENSQ1           YES, PROCEED.
         CAL1,1   CLSLAST           CLOSE AND REMOVE TAPEIF NOT SQ
         STW,R0   NOTAPFG           CLEAR THE TAPE MOUNTED FLAG
OPENSQEX EQU      $
         LI,R7    MVENT
         B        MESSINIT          OPEN IT THE OTHER WAY.
OPENSQ1  EQU      $
         LB,R5    LBLORG
         CI,R5    X'FF'             LOOK FOR THE LAST FILE.
         BE       OPENSQ2           GOT IT
         CAL1,1   CLSEOSAV
         CAL1,1   EOINOUT           GET NEXT FILE
         B        OPENSQ1            AND CONTINUE LOOKING
OPENSQ2  EQU      $
         CAL1,1   CLSEOPTL          MOVE BACK OVER LAST FILE
         B        OPENSQEX          MOVE THE TAPE FROM LASTFILE
+1501,1501
*
*        BAL,R7   MESSINIT
*
*        INPUT:   F:EI DCB WHICH IS OPEN TO FILE TO BE SAVED.
*        OUTPUT:  PBUFFER (LINE PRINTER BUFFER) IS BLANK FILLED AND
*                 THE FILE NAME AND ACCOUNT OF THE F:EI DCB ARE MOVED
*                 INTO IT.
*                 R12-R13 CONTAIN THE ACCOUNT NAME FOR THE FILE.
*        USES:    R4,R5,R6,R12,R13
*
MESSINIT EQU      $
+1513,1515
+1520
         B        0,R7              RETURN
*
MVENT    EQU      $
+1666,1670        LLF               #21724     10/18/74
         LI,D3    X'4000'
         CW,D3    EI:DESC+1         CHECK FOR SYNONOMOUS FILE
         BAZ      SETLORG1          NOT SYNON
*
         LI,D3    X'0B'
         STB,D3   FPAR              CHANGE 01 TO 0B (PARENT NAME IN FPAR)
         LI,D4    FPAR
         LI,D3    LBLVLPS
         BAL,R5   MOVEVLP           MOVE SYNON VLP INTO LABEL
         STW,D3   REGS              SAVE THE LABEL VLP POINTER
         LI,D3    X'909'            FPAR VLP IS 9 WORDS FOR SOME REASON
         STH,D3   VPT:EI,R1          SO KEEP EVERYONE HAPPY.
         LI,D3    FPAR
         LI,D4    VPT:EI            PUT REAL FILE NAME IN FPAR(SYNON)
         BAL,R5   MOVEVLP
         LD,R4    ORGMBS
         MBS,R4   0
         LW,D3    REGS              RESTORE D3
         B        SETLORG2
SETLORG1 EQU      $
         LI,D3    LBLVLPS
SETLORG2 EQU      $
+1783
         STB,R0   MOV:FPT+1,R3      DON'T FORCE BLOCK FOR RANDOM FILES
+1785,1785
NORAND   EQU      $
         STB,R1   MOV:FPT+1,R3      FORCE BLOCKING IN MOVE CAL
         CI,R5    2
+1852,1869
CLS:B    EQU      $
         CAL1,1   CLOSBACK
+1896,1896
+1912,1912
         BE       CLS:B
+1926,1926
         BE       CLS:B
+1928,1928
         BE       CLS:B
+1941
         PAGE
*
*        ERROR/ABNORMAL ROUTINE FOR F:EO BEING OPENED INOUT
*         FOR A SPACE TO END OF TAPE, USER BACKUP COMBO.
*
SQABN    EQU      $
         LB,R6    R10
         CI,R6    X'14'
         BNE      SQABN1
         LB,R6    R10,R1
         SLS,R6   -1
         CI,R6    3                 INTERRUPT OF MOUNT CASE
         BNE      SQABN1
         AI,R8    -1
         LCI      0
         MTW,0    INT
         BEZ      *R8               CONTROL Y OR SOME SUCH
         STW,R8   ABNEXIT
         BAL,SR4  PURGE
         B        *ABNEXIT
SQABN1   EQU      $
         LCI      0
         STM,R0   REGS
         BAL,R3   SNAPPER           DON'T ANTICIPATE ANY ERRORS
         CAL1,1   OPNDEVTP          OPEN TAPE TO REMOVE IT
         CAL1,1   CLSLAST
         STW,R0   NOTAPFG           CLEAR TAPE MOUNTED FLAG
         B        OPENSQEX          DO IT THE OLD WAY.
+1975
         LCI      0
         STM,R0   REGS
         BAL,R3   SNAPPER           GET SOME INFORMATION
NDUSR1   EQU      $
+2005,2005
         BE       NDUSR
+2009,2025
         BNE      NDUSR             FLICK IT IN
         LB,R5    R10,R1            CHECK FOR JUST BUSY
         AND,R5   R2                BUSY BIT
         BEZ      NDUSR             NOT BUSY, SNAP HIM
         BAL,SR2  SEND:ERR          LOG BUT DON'T SNAP
         B        NDUSR1
+2045,2045
         DATA     MOV:ERR           WILL TRAP TO TRAPPER
+2076,2078
+2086,2086
         LW,D4    BLDMAIL           ARE WE BUILDING MAILBOXES?
+2087
         LW,D4    USRFLG            IF NOT A USER TYPE BACKUP
         BEZ      OPN:BCK            DON'T BUILD A MAILBOX.
+2101,2101
         STB,R6   R5
+2111,2111
+2154,2157
+2159,2159
         LCI      0
         STM,R0   REGS
         BAL,R3   SNAPPER           CHECK THIS OUT
         B        CLS:B
+2179,2179
+2206
         LCI      0
         STM,R0   REGS
+2208,2208
+2236,2237        #22975
ERR75    EQU      $
         LCI      3
         PSM,SR1  ENVIR             SAVE VOLATILE REGS
         BAL,R7   MESSINIT          SET UP THE LINE PRINTER MESSAGE
+2238
         LI,R5    ERRBUF
         CAL1,2   TYPE
+2239,2239
         LCI      3
         PLM,SR1  ENVIR             RECOVER THE REGS
         LB,R6    R10,R1            GET SUBCODE OF 75 ERROR
+2242,2242
         BL       OPNNXF            ONLY FILE IS BAD
+2245,2246
+2261
         LCI      0
         STM,R0   REGS
         BAL,R3   SNAPPER
+END
