Google
 

Trailing-Edge - PDP-10 Archives - SRI_NIC_PERM_SRC_3_19910112 - mm/mmlbx.dif
There are no other files named mmlbx.dif in the archive.

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 1



LINE 1, PAGE 1
1)	;[SRI-NIC]SRC:<MM>MMLBX.MAC.39, 10-Jul-85 19:51:53, Edit by HSS
1)	; Add local changes to support MMAILR -RELAY code
1)	
1)		TITLE MMailbox Mailing lists for MMailr
LINE 1, PAGE 1
2)		TITLE MMailbox Mailing lists for MMailr


LINE 8, PAGE 1
1)	VMAJOR==5			;TOPS-20 release 5.4
1)	VMINOR==4
1)	VMMLBX==^D40			;MMLBX's version number
1)	
LINE 5, PAGE 1
2)	VMAJOR==6			;TOPS-20 release 6.1
2)	VMINOR==1
2)	VMMLBX==^D55			;MMLBX's version number
2)	


LINE 14, PAGE 3
1)	 HSHMD0==^D4999			;Magic prime number for hash modulus
1)	 HSHFRE==1000			;Space at end of hash table
LINE 14, PAGE 3
2)	 HSHMD0==^D15013		;Magic prime number for hash modulus
2)	 HSHFRE==1000			;Space at end of hash table


LINE 52, PAGE 4
1)		NOP			;+4 Forward address from FINGER database
1)		MOVEI A,3		;+5 Mailing list
LINE 52, PAGE 4
2)		 NOP			;+4 Forward address from FINGER database
2)		MOVEI A,3		;+5 Mailing list


LINE 15, PAGE 6
1)		  SETZM FNGFRK		;No FINGER fork just yet
LINE 15, PAGE 6
2)		  SETZM BINJFN		;No binary JFN yet
2)		  SETZM FNGFRK		;No FINGER fork just yet

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 2



LINE 43, PAGE 6
1)		HRROI A,LCLNAM
LINE 44, PAGE 6
2)		HRROI A,MLSBNM		;Set up binary file name
2)		HRRZ B,MLSJFN		;JFN of text file
2)		MOVE C,[110000,,1]	;Device and directory
2)		JFNS%
2)		HRROI B,[ASCIZ/MAILING-LISTS.BIN;P777752/]
2)		SETZ C,
2)		SOUT%			;Append our filename to it
2)		HRROI A,LCLNAM


LINE 2, PAGE 7
1)	;;; Map in new binary file and see if we can use it
1)	
1)		DO.
1)		  AOSE RUNP		;Is this the first time we've been run?
1)		  IFSKP.
1)		    HRROI A,MLSBNM	;Set up binary file name
1)		    HRRZ B,MLSJFN	;JFN of text file
1)		    MOVE C,[110000,,1]	;Device and directory
1)		    JFNS%
1)		    HRROI B,[ASCIZ/MAILING-LISTS.BIN;P777752/]
1)		    SETZ C,
1)		    SOUT%		;Append our filename to it
1)		    CALL MAPBIN		;Map in binary file
1)		     EXIT.		;Failed, must compile new binary
1)		  ENDIF.
1)		  SKIPN A,BINJFN	;Have a binary file?
1)		   EXIT.		;No, must compile new one
1)		  MOVE B,[1,,.FBWRT]	;Get time of last write of binary file..
1)		  MOVEI C,D
1)		  GTFDB%
1)		  CAME T,WRTTIM		;Write time of text file?
1)		   CAML D,T		;Binary likely from text?
1)		  IFSKP.
1)		    SKIPN RUNP		;No, did we just read the binary file?
1)		    IFSKP.
1)		      SETOM RUNP	;No, perhaps there is a new binary
1)		      CALL UMPBIN	; file to accompany the text file
1)		      LOOP.
1)		    ENDIF.
1)		    SKIPN WHEEL		;Can we change the BIN file?
1)		  ANSKP.
1)		  ELSE.
1)		    MOVE A,MLSJFN	;Nothing more to do, flush the text JFN
LINE 2, PAGE 7
2)	;;; Map in binary file and see if we can use it

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 3


2)	
2)		DO.
2)		  SKIPE A,BINJFN	;Have a binary file?
2)		  IFSKP.
2)		    TXO F,FL%CMP	;No, must compile unless can find one
2)		    SETZM CMPPDP	;Don't have compiling stack yet
2)		    CALL MAPBIN		;Map in binary file
2)		     EXIT.		;Failed completely, must compile
2)		  ENDIF.
2)	REPEAT 0,<
2)	;;;  Fall-back code to use if it turns out that too many problems occur
2)	;;; with multiple MMailbox processes trying to recompile the binary file
2)		  SKIPN HAVSUP		;Have a superior?
2)		   SKIPN WHEEL		;No, is user a Wheel?
2)		  IFSKP.		;No superior and user is a Wheel
2)	>;REPEAT 0
2)	REPEAT 1,<
2)	;;;  Here to allow recompiling of the binary file only if MMailbox is run
2)	;;; manually by a Wheel or if invoked by MMailr
2)		  SKIPE HAVSUP		;Have a superior?
2)		   SKIPE MAISUP		;Yes, is MMailr the superior?
2)		  IFNSK.		;No superior or MMailr is the superior
2)		    SKIPN WHEEL		;Only look into recompiling if Wheel
2)		  ANSKP.
2)	>;REPEAT 1
2)		    MOVE B,[1,,.FBWRT]	;Get time of last write of binary file
2)		    MOVEI C,D		; into D
2)		    GTFDB%
2)		    CAML D,T		;Binary newer than text?
2)		     CAME T,WRTTIM	;Yes, does its WRTTIM match write time of text?
2)		  ANNSK.
2)		    CALL UMPBIN		;Binary file out of date, toss it
2)		    JXE F,FL%CMP,TOP.	;If didn't just map it in, try again
2)		  ELSE.
2)		    TXZ F,FL%CMP	;Not compiling any more
2)		    MOVE A,MLSJFN	;Nothing more to do, flush the text JFN


LINE 3, PAGE 8
1)		TXO F,FL%CMP		;Flag compiling binary file
1)		MOVEM P,CMPPDP		;Save compiling stack
LINE 3, PAGE 8
2)		MOVEM P,CMPPDP		;Save compiling stack

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 4



LINE 12, PAGE 8
1)		CALL UMPBIN		;Unmap old binary
1)	
LINE 11, PAGE 8
2)	


LINE 66, PAGE 8
1)		MOVE I,[-HSHLEN,,HSHTAB]
LINE 64, PAGE 8
2)		TXZ F,FL%ADI!FL%PRV	;Don't bother with indirect files
2)		MOVE W,[IOWD LPNPDL,LPPDL] ;Init forwarding loop stack
2)		MOVE I,[-HSHLEN,,HSHTAB]


LINE 70, PAGE 8
1)		    HLRZ J,(I)		;Yes, get start of addresses
LINE 70, PAGE 8
2)		    HRRZ E,(I)		;Get this address
2)		    PUSH W,E		;First one to check
2)		    HLRZ J,(I)		;Yes, get start of addresses


LINE 75, PAGE 8
1)			CALL EXPADR	;Yes, expand it, no indirect files
1)			AOJA J,TOP.
1)		      ENDIF.
1)		    ENDDO.
1)		    SETZM (O)		;Mark new end
1)		    ADDI O,1
1)		  ENDIF.
LINE 77, PAGE 8
2)			CALL CKLOOP	;Looping on this address?
2)			 JRST EXPLPX	;Yes
2)			PUSH W,E	;No, save the address being expanded
2)			CALL EXPAD0
2)			ADJSP W,-1	;Reduce loop stack
2)			AOJA J,TOP.
2)		      ENDIF.
2)		    ENDDO.
2)		    SETZM (O)		;Clear last entry
2)		    ADDI O,1
2)		    ADJSP W,-1		;Pop first address
2)		  ENDIF.

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 5



LINE 119, PAGE 8
1)		CALL MAPBIN		;Map it back in for read now
LINE 126, PAGE 8
2)		SETZM CMPPDP		;Don't have compiling stack any more
2)		CALL MAPBIN		;Map it back in for read now


LINE 132, PAGE 8
1)		HRROI B,[ASCIZ/
1)	/]
1)		SOUT%
1)		JRST IERR1
LINE 140, PAGE 8
2)		JRST IERR1


LINE 22, PAGE 9
1)		JUMPE B,CPYSTR		;If no host name, copy string and return
1)		CAME B,[POINT 7,STRBUF,6] ;Was the @ the first character?
LINE 22, PAGE 9
2)		IFE. B			;If no host name, copy string and return
2)		  SAVEAC <T,TT>
2)		  MOVEI T,STRBUF	;Is this name in hash table?
2)		  CALL HSHLUK		;Well?
2)		   JRST CPYSTR		;No, just copy it then
2)		  HRRZ E,(I)		;Yes, use that value
2)		  RET
2)		ENDIF.
2)		CAME B,[POINT 7,STRBUF,6] ;Was the @ the first character?


LINE 9, PAGE 11
1)		  PUSH P,I		;Save last index as temporary also
1)		  CALL HSHLUK		;Look it up
1)		  IFSKP.
1)		    POP P,T		;Expansion found, retrieve last index
1)		    CAME T,I		;Same?
1)		     JRST EXPAN0	;No, recurse
1)	;;; If the indices are the same, then we've reached a self-defined
1)	;;;expansion. This is probably a user on this system which had
1)	;;;the host name stripped by CANADR.
1)		  ELSE.
1)		    ADJSP P,-1		;Flush old index
1)		  ENDIF.
LINE 9, PAGE 11
2)		  CALL HSHLUK		;Look it up
2)		  IFSKP.
2)		    CALLRET EXPAN0	;No, recurse
2)		  ENDIF.

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 6




LINE 9, PAGE 12
1)	CKLOOP:	SAVEAC <A,B>		;Save working ACs
1)		MOVE A,[IOWD LPNPDL,LPPDL] ;Start of stack
LINE 9, PAGE 12
2)	CKLOOP:	SAVEAC <A>		;Save working AC
2)		MOVE A,[IOWD LPNPDL,LPPDL] ;Start of stack


LINE 42, PAGE 13
1)		     JRST FNGSIM
1)		  ENDIF.
1)		  TXO F,FL%RLY		;Local, flag must simulate FINGER return
1)		ENDIF.
1)		HRROI A,STRBF1		;[39] Make request list address here
1)		HRROI B,ADDRES		;[39] From the passed in list
1)		SETZ C,			;[39]
1)		SOUT%			;[39]
1)		HRROI B,[ASCIZ/-RELAY/] ;[39] Add in RELAY part
1)		SOUT%			;[39]
1)		MOVEI T,STRBF1		;[39] Get address of request list
1)		CALL HSHLUK		;[39] See if it exists
1)		 SKIPA			;[39] No
1)		AOS SUCES1		;[39] Yes, tell superior, MMAILR
1)		MOVEI T,ADDRES		;Address of user string
LINE 42, PAGE 13
2)		    JRST FNGSIM
2)		  ENDIF.
2)		  TXO F,FL%RLY		;Local, flag must simulate FINGER return
2)		ENDIF.
2)		MOVEI T,ADDRES		;Address of user string


LINE 26, PAGE 14
1)		MOVX A,RC%EMO		;A>B see if user name, require exact match
1)		HRROI B,ADDRES		;Proposed user name string
1)		RCUSR%			;Parse it
1)		 ERJMP CPOPJ		;If garbage characters, punt it completely
1)		IFXE. A,RC%NOM!RC%AMB	;Was it a user name?
LINE 26, PAGE 14
2)		MOVX A,RC%EMO		;A.ne.B see if user name, require exact match
2)		LDB B,[POINT 7,ADDRES,6] ;Get first character of name
2)		CAIN B,"&"		;Allow special syntax meaning local user
2)		 SKIPA B,[POINT 7,ADDRES,6] ;It was, so slide over by 1
2)		  MOVE B,[POINT 7,ADDRES] ;Proposed user name string
2)		MOVE C,B		;See if null string
2)		ILDB C,C		;Get first byte in string
2)		JUMPE C,R		;If null, punt it completely
2)		RCUSR%			;Parse it
2)		 ERJMP R		;If garbage characters, punt it completely

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 7


2)		IFXE. A,RC%NOM!RC%AMB	;Was it a user name?


LINE 42, PAGE 14
1)		 JRST [	MOVE A,[POINT 7,STRBUF] ;Buffer to use
1)			MOVEI B,[ASCIZ/[email protected]/] ;Default BUG-MM host
1)			CALL MOVSTR	;Copy the string
1)			JRST FNGSIM]	;Simulate data returned from FINGER
1)		 NOP			;A<B return, no-op to A>B return
1)		MOVE A,[POINT 7,ADDRES]	;Check to see if SYSTEM mail
LINE 48, PAGE 14
2)		IFNSK.
2)		  MOVE A,[POINT 7,STRBUF] ;Buffer to use
2)		  MOVEI B,[ASCIZ/[email protected]/] ;Default BUG-MM host
2)		  CALL MOVSTR		;Copy the string
2)		  JRST FNGSIM		;Simulate data returned from FINGER
2)		ENDIF.
2)		MOVE A,[POINT 7,ADDRES]	;Check to see if SYSTEM mail


LINE 51, PAGE 14
1)		 NOP			;A<B
1)	
1)	; falls through
1)	^L
1)	; drops in
1)	
LINE 58, PAGE 14
2)	


LINE 16, PAGE 16
1)		TXNN A,SC%SUB		;Is "BUG-" a subset of user's string?
1)		 RET			;No, address fails utterly
1)		MOVEI T,[ASCIZ/BUG-RANDOM-PROGRAM/] ;Yes, return BUG-RANDOM-PROGRAM
1)		CALL HSHLUK
1)		 RET			;Not present, address fails utterly
LINE 16, PAGE 15
2)		IFXN. A,SC%SUB		;Is "BUG-" a subset of user's string?
2)		  MOVEI T,[ASCIZ/BUG-RANDOM-PROGRAM/] ;Yes, return BUG-RANDOM-PROGRAM
2)		  CALL HSHLUK
2)		   RET			;Not present, address fails utterly
2)		  JRST CPOP4J		;Return forwarded address
2)		ENDIF.
2)		HRROI A,[ASCIZ/HELP-/]	;Prefix for HELP
2)		HRROI B,ADDRES		;User's string
2)		STCMP%
2)		JXE A,SC%SUB,R		;Fail if not a substring
2)		MOVEI T,[ASCIZ/HELP-RANDOM-PROGRAM/]
2)		CALL HSHLUK		;Substring, return HELP-RANDOM-PROGRAM
2)		 RET			;Not present, address fails utterly

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 8




LINE 7, PAGE 17
1)	HSHLUK:	PUSH P,A
1)		PUSH P,B
1)		HRLI T,(<POINT 7,0>)
1)		PUSH P,T		;Save string pointer
1)		CALL HASH		;Hash string into number
1)		PUSH P,TT		;Save first index
1)		SKIPA T,TT
1)	HSHLK1:	 AOS T,(P)
1)		IDIV T,HSHMOD		;Divide by modulus
1)		SKIPN A,HSHTAB(TT)	;Look for entry here
1)		 JRST HSHLKN		;Not found, return
1)		HRLI A,(<POINT 7,0>)
1)		MOVE B,-1(P)		;Given string
1)		CALL CMPSTR		;Compare strings
1)		 JRST HSHLKO		;Match, found
1)		 NOP
1)		JRST HSHLK1
1)	
1)	HSHLKO:	AOS -4(P)
1)	HSHLKN:	MOVEI I,HSHTAB(TT)	;Return absolute pointer
1)		ADJSP P,-2
1)		POP P,B
1)		POP P,A
1)		RET
1)	
1)	;;; Hash string in T until null
1)	HASH:	PUSH P,C
1)		SETZ TT,
1)	HASH1:	ILDB C,T
1)		JUMPE C,HASH2
1)		LSH TT,7
1)		TRZ C,40		;Case independent
1)		XORI TT,(C)
1)		JRST HASH1
1)	
1)	HASH2:	TLC TT,(TT)		;Make positive (18-bits)
1)		HLRZ TT,TT
1)		JRST CPOPCJ
1)	^L
1)	;;; Compare strings in A and B
1)	;;; +1 same, +2 A<B, +3 A>B
1)	CMPSTR:	PUSH P,C
1)		PUSH P,D
1)	CMPST1:	ILDB C,A
1)		CAIL C,"a"
1)		 CAILE C,"z"
1)		  CAIA
1)		   SUBI C,"a"-"A"

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 9


1)		ILDB D,B
1)		CAIL D,"a"
1)		 CAILE D,"z"
1)		  CAIA
1)		   SUBI D,"a"-"A"
1)		CAME C,D
1)		 JRST CMPST2
1)		JUMPE C,CMPST6		;Strings match
1)		JRST CMPST1
1)	
1)	CMPST2:	CAML C,D
1)		 AOS -2(P)		;A greater
1)		AOS -2(P)
1)	CMPST6:	POP P,D
1)		POP P,C
1)		RET
1)	
1)	;;; Copy string from STRBUF
1)	;;;        N/ pointer to string free space
1)	CPYSTR:	PUSH P,A
1)		PUSH P,B
1)		MOVE A,[POINT 7,STRBUF]
LINE 7, PAGE 16
2)	HSHLUK:	SAVEAC <A,B>
2)		STKVAR <HSHSTR,HSHIDX>
2)		HRLI T,(<POINT 7,0>)
2)		MOVEM T,HSHSTR		;Save string pointer
2)		CALL HASH		;Hash string into number
2)		MOVEM TT,HSHIDX		;Save first index
2)		MOVE T,HSHIDX
2)		DO.
2)		  IDIV T,HSHMOD		;Divide by modulus
2)		  SKIPN A,HSHTAB(TT)	;Look for entry here
2)		   EXIT.		;Not found, return
2)		  HRLI A,(<POINT 7,0>)
2)		  MOVE B,HSHSTR		;Given string
2)		  CALL CMPSTR		;Compare strings
2)		  IFSKP.
2)		    AOS T,HSHIDX
2)		    LOOP.
2)		  ENDIF.
2)		  AOS (P)		;Set success return
2)		ENDDO.
2)		MOVEI I,HSHTAB(TT)	;Return absolute pointer
2)		RET
2)	
2)		ENDSV.
2)	
2)	;;; Hash string in T until null
2)	HASH:	SAVEAC <C>
2)		SETZ TT,

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 10


2)		DO.
2)		  ILDB C,T
2)		  JUMPE C,ENDLP.
2)		  LSH TT,7
2)		  TRZ C,40		;Case independent
2)		  XORI TT,(C)
2)		  LOOP.
2)		ENDDO.
2)		TLC TT,(TT)		;Make positive (18-bits)
2)		HLRZ TT,TT
2)		RET
2)	^L
2)	;;; Compare strings in A and B
2)	;;; +1 same, +2 different
2)	CMPSTR:	SAVEAC <C,D>
2)		DO.
2)		  ILDB C,A
2)		  CAIL C,"a"
2)		   CAILE C,"z"
2)		    CAIA
2)		     SUBI C,"a"-"A"
2)		  ILDB D,B
2)		  CAIL D,"a"
2)		   CAILE D,"z"
2)		    CAIA
2)		     SUBI D,"a"-"A"
2)		  CAME C,D
2)		  IFSKP.
2)		    JUMPN C,TOP.	;More to do
2)		    RET			;Strings match
2)		  ENDIF.
2)		ENDDO.
2)		RETSKP			;Strings don't match
2)	
2)	;;; Copy string from STRBUF
2)	;;;        N/ pointer to string free space
2)	CPYSTR:	SAVEAC <A,B>
2)		MOVE A,[POINT 7,STRBUF]


LINE 40, PAGE 18
1)		POP P,B
1)		POP P,A
1)		RET
LINE 35, PAGE 17
2)		RET

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 11



LINE 52, PAGE 18
1)		PUSH P,C		;Working ac
1)	MOVST0:	ILDB C,B
1)		JUMPE C,MOVST1		;Quit on null
1)		IDPB C,A
1)		JRST MOVST0
1)	
1)	; Here to finish ASCIZ string
1)	MOVST1:	PUSH P,A		;Save dest ptr so can continue string
1)		IDPB C,A
1)	POPACJ:	POP P,A
1)		POP P,C
1)		RET
LINE 45, PAGE 17
2)		SAVEAC <C>
2)		DO.
2)		  ILDB C,B
2)		  JUMPE C,ENDLP.	;Quit on null
2)		  IDPB C,A
2)		  LOOP.
2)		ENDDO.
2)	
2)	; Here to finish ASCIZ string
2)		PUSH P,A		;Save dest ptr so can continue string
2)		IDPB C,A
2)		POP P,A
2)		RET


LINE 12, PAGE 19
1)		PUSH P,C
1)		PUSH P,D
1)	REDTOP:	MOVE C,[POINT 7,STRBUF]	;Where to put it
LINE 12, PAGE 18
2)		SAVEAC <C,D>
2)	REDTOP:	MOVE C,[POINT 7,STRBUF]	;Where to put it


LINE 50, PAGE 19
1)		POP P,D
1)	CPOPCJ:	POP P,C
1)	CPOPJ:	RET
1)	
LINE 49, PAGE 18
2)		RET
2)	

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 12



LINE 66, PAGE 19
1)		CAIN B,QUOTE		;Second quote?
1)		 JRST RDQOT1
1)	RDQOT2:	SOJL D,REDTLG		;No, insert quoted character into buffer
1)		IDPB B,C
1)		JRST REDQOT
1)	
1)	RDQOT1:	CALL FILTYI		;Peek at next character
1)		CAIN B,QUOTE		;Was it a doubled quote?
1)		 JRST RDQOT2		;Yes, insert single quote in string
1)		MOVEM C,ENDPOS		;No, end of quoted string
1)		JRST REDLP1		;Enter loop with next character in B
1)	
1)	;;;Skip trailing whitespace, enter SKPWHT with terminator in B
1)	SKPWHT:	MOVE D,B		;Keep track of whether we get a CR
1)	SKPWH1:	CALL FILTYI		;Get a byte
1)		CAIE B," "		;Space?
1)		 CAIN B,.CHTAB		;Or TAB?
1)		  JRST SKPWH1		;Yes, skip to next
1)		JUMPE B,SKPWH1		;Skip nulls
1)	SKPWH2:	CAIN B,.CHCRT		;Remember if we get a CR
1)		 JRST SKPWHT
1)		JUMPL B,REDRET		;Return EOF
1)		CAIN B,";"		;Comment?
1)		 JRST [ CALL REDCM1	;Yes, flush and check terminator
1)			JRST SKPWH2]
1)		CAIN B,"!"		;Inline comment?
1)		 JRST [ CALL REDXC1	;Yes, flush
1)			CAIN B,"!"	;If ended on matching excl, get next char
1)			 JRST SKPWH1
1)			JRST SKPWH2]	;Check terminator
1)		CAIN B,"-"              ;Dash?
1)		 JRST [ CALL REDDS1     ;Followed by CR is no-op, else is good char 
1)			 JRST SKPWH1
1)			JRST .+1]       ;Two BKJFNs, bombs here for TTY:!
1)		BKJFN			;None of those, back up over char
1)		 NOP
1)		MOVE B,D		;And return saved CR or terminator
1)		JRST REDRET
1)	
LINE 63, PAGE 18
2)		CAIE B,QUOTE		;Second quote?
2)		IFSKP.
2)		  CALL FILTYI		;Peek at next character
2)		  CAIN B,QUOTE		;Was it a doubled quote?
2)		ANSKP.			;Yes, insert single quote in string
2)		  MOVEM C,ENDPOS	;No, end of quoted string
2)		  JRST REDLP1		;Enter loop with next character in B
2)		ENDIF.

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 13


2)		SOJL D,REDTLG		;No, insert quoted character into buffer
2)		IDPB B,C
2)		JRST REDQOT
2)	
2)	;;;Skip trailing whitespace, enter SKPWHT with terminator in B
2)	SKPWHT:	MOVE D,B		;Keep track of whether we get a CR
2)		DO.
2)		  CALL FILTYI		;Get a byte
2)		  CAIE B," "		;Space?
2)		   CAIN B,.CHTAB	;Or TAB?
2)		    LOOP.		;Yes, skip to next
2)		  JUMPE B,TOP.		;Skip nulls
2)		  DO.
2)		    CAIN B,.CHCRT	;Remember if we get a CR
2)		     JRST SKPWHT
2)		    CAIE B,"-"		;Dash?
2)		    IFSKP.
2)		      CALL REDDS1	;Followed by CR is no-op, else is good char 
2)		    ANSKP.
2)		      MOVE B,D
2)		      JRST SKPWHT
2)		    ENDIF.
2)		    JUMPL B,REDRET	;Return EOF
2)		    CAIE B,";"		;Comment?
2)		    IFSKP.
2)		      CALL REDCM1	;Yes, flush and check terminator
2)		      LOOP.
2)		    ENDIF.
2)		    CAIN B,"!"		;Inline comment?
2)		    IFSKP.
2)		      BKJFN%		;None of those, back up over char
2)		       NOP
2)		      MOVE B,D		;And return saved CR or terminator
2)		      JRST REDRET
2)		    ENDIF.
2)		    CALL REDXC1		;Yes, flush
2)		    CAIE B,"!"		;Ended on matching excl?
2)		     LOOP.		;No, check terminator
2)		  ENDDO.
2)		  LOOP.			;Yes, get next character and continue
2)		ENDDO.
2)	

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 14



LINE 113, PAGE 19
1)	WITTYI:	PUSHJ P,FILTYI
1)		JUMPE B,WITTYI		;Ignore nulls
LINE 121, PAGE 18
2)	WITTYI:	CALL FILTYI
2)		JUMPE B,WITTYI		;Ignore nulls


LINE 133, PAGE 19
1)	REDCM1:	PUSHJ P,FILTYI
1)		JUMPL B,CPOPJ
1)		CAIE B,.CHCRT
LINE 141, PAGE 18
2)	REDCM1:	CALL FILTYI
2)		JUMPL B,R
2)		CAIE B,.CHCRT


LINE 143, PAGE 19
1)		JUMPL B,CPOPJ
1)		CAIE B,"!"
LINE 151, PAGE 18
2)		JUMPL B,R
2)		CAIE B,"!"


LINE 153, PAGE 19
1)	REDDS1:	PUSHJ P,FILTYI
1)		JUMPL B,REDDS2
1)		CAIN B,.CHCRT
1)		 RET
1)		BKJFN
1)		 NOP
LINE 161, PAGE 18
2)	REDDS1:	CALL FILTYI
2)		JUMPL B,REDDS2
2)		CAIN B,.CHCRT
2)		 RET
2)		BKJFN%
2)		 NOP

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 15



LINE 3, PAGE 20
1)	MAPBIN:	SETZM BINJFN
1)		MOVX A,GJ%OLD!GJ%SHT!GJ%PHY
1)		HRROI B,MLSBNM
1)		GTJFN%
1)		 JRST [	HRROI A,[ASCIZ/Cannot find mailing list binary file/]
1)			RET]
1)		MOVEI B,OF%RD
1)		OPENF%
1)		 JRST [	HRROI A,[ASCIZ/Cannot open mailing list binary file/]
1)			RET]
1)		MOVEM A,BINJFN
1)		MOVE B,[1,,.FBBYV]
LINE 3, PAGE 19
2)	MAPBIN:	CALL UMPBIN		;Toss out what might have been there before
2)		MOVX A,GJ%OLD!GJ%SHT!GJ%PHY ;Try to get binary file
2)		HRROI B,MLSBNM
2)		GTJFN%
2)		IFJER.
2)		  HRROI A,[ASCIZ/Cannot find mailing list binary file/]
2)		  RET
2)		ENDIF.
2)		PUSH P,A		;Save JFN
2)		MOVEI B,OF%RD		;Now try to open it
2)		OPENF%
2)		IFJER.
2)		  POP P,A		;Get back JFN
2)		  RLJFN%		;Flush it
2)		   NOP
2)		  HRROI A,[ASCIZ/Cannot open mailing list binary file/]
2)		  RET
2)		ENDIF.
2)		POP P,BINJFN		;Set BINJFN now that it's open
2)		MOVE B,[1,,.FBBYV]


LINE 23, PAGE 20
1)		CAME A,[SIXBIT /MMLBX/]
1)		 JRST [	HRROI A,[ASCIZ/Bad format binary file/]
1)			RET]
1)		AOS (P)
1)		RET
1)	
LINE 31, PAGE 19
2)		CAMN A,[SIXBIT/MMLBX/]
2)		IFSKP.
2)		  CALL UMPBIN		;Unmap the sucker
2)		  HRROI A,[ASCIZ/Bad format binary file/]
2)		  RET

; MMLBX.MAC.39 & <MM-NEW>MMLBX.MAC.55 13-Aug-87 1607	PAGE 16


2)		ENDIF.
2)		MOVE A,BINJFN		;Return with JFN in A
2)		RETSKP
2)	


LINE 35, PAGE 20
1)		MOVE A,BINJFN
1)		CLOSF%
1)		 NOP
1)		SETZM BINJFN
LINE 46, PAGE 19
2)		SKIPE A,BINJFN
2)		 CLOSF%
2)		  NOP
2)		SETZM BINJFN


LINE 30, PAGE 21
1)		SKIPN HAVSUP
1)		 ESOUT%
1)		TXZN F,FL%CMP		;Compiling binary file?
LINE 30, PAGE 20
2)		SKIPE HAVSUP
2)		IFSKP.
2)		  ESOUT%
2)		  TMSG <
2)	>
2)		ENDIF.
2)		TXZN F,FL%CMP		;Compiling binary file?


LINE 37, PAGE 21
1)		  RET			;A-okay
LINE 41, PAGE 20
2)		  TMSG <[Using previous version of database]
2)	>
2)		  RET			;A-okay


LINE 42, PAGE 21
1)	END <EVECL,,EVEC>
LINE 48, PAGE 20
2)	...LIT:	LIT
2)	
2)	END <EVECL,,EVEC>