Google
 

Trailing-Edge - PDP-10 Archives - bb-bt99g-bb - filuuo.c09
There is 1 other file named filuuo.c09 in the archive. Click here to see a list.
 REP 11/32	;09C1
		PUSH	P,T1		;SAVE L(A.T.)
		MOVE	P2,T1		;P2= SL. PTR.
 WIT
		PUSH	P,T1		;SAVE SL PTR
		SETZ	P1,		;COUNT NUMBER OF STRS IN SL
		MOVE	P2,T1
	UFDSR5:	PUSHJ	P,SLITA##
		 SKIPA	P2,(P)		;RESET SL PTR
		AOJA	P1,UFDSR5
		SOJE	P1,UFDSR3	;ONLY ONE STR, LEAVE THINGS ALONE
	;HERE WITH P1 NON-0
 REP 24/32	;09C2
		TLZ	M,UUOMSK	;SET UUO TO LOOK LIKE A LOOKUP
 WIT
	UFDSR6:	TLZ	M,UUOMSK	;SET UUO TO LOOK LIKE A LOOKUP
 DEL 5/33	;09C3
		TLZ	S,IOEND		;IT ISNT REALLY AN EOF YET
 REP 9/33	;09C4
		PJRST	INPTU		;DO 1ST INPUT ON NEW DIRECTORY FILE

	;HERE WHEN WE FOUND THE LAST DIRECTORY
	UFDSR4:	SETZM	DEVUNI##(F)	;PREVENT USETI FROM "WINNING"
 WIT
		JUMPE	P1,STOIOS##	;JUST RE-OPENED 1ST STR, GIVE EOF RETURN
		TLZ	S,IOEND		;IT ISN'T REALLY AN EOF YET
		PJRST	INPTU		;DO 1ST INPUT ON NEW DIRECTORY FILE
	;HERE WHEN SL IS EXHAUSTED
	UFDSR4:	MOVE	P2,(P)		;RESET SL PTR TO BEGINING
		TRZE	P1,-1		;1ST TIME HERE?
		JRST	UFDSR6		;YES, RE-OPEN 1ST STR (SO REWIND WORKS)
		PUSHJ	P,JDAADR##	;2ND TIME (STR YANKED)
		HLLM	F,(T1)		;CLEAR LOOKB IN USRJDA
		SETZM	DEVUNI##(F)	;FILE IS LEFT CLOSED SO USETI UUO
					;WOULD BE INTERPRETED AS SUPER USETI.
					;ZERO DEVUNI TO MAKE USETI FAIL.
 REP 30/44	;09C5
		CAIN	T1,AEFERR	;CAN'T - SUPERSEDE ERROR?
 WIT
		TLZ	T1,-1
		CAIE	T1,FBMERR	;FILE BEING MODIFIED?
		CAIN	T1,AEFERR	;OR SUPERSEDE ERROR?
 REP 6/151	;09C6
	PTHU24:	SKIPE	DEVPPN(F)	;LOOKUP DONE?
		JRST	PTHU25		;YES--TELL THE TRUTH
		CAIE	P3,ZPPNDX##	;ALL?
		MOVEI	T2,0		;NO--NO SFD'S
		SKIPG	T1,@SDVPPN(P3)	;AND GET DEFAULT PPN
 WIT
	PTHU24:	HRRZ	T1,DEVACC##(F)	;LOOKUP DONE?
		JUMPN	T1,PTHU25	;YES, GO TELL THE TRUTH
		SKIPLE	T1,@SDVPPN(P3)	;IS THERE AN IMPLIED PPN?
		TDZA	T2,T2		;YES, FLAG NOT TO USE SFDS FROM DEFAULT PATH
 REP 3/186	;09C7
		PUSHJ	P,SETVAL	;STORE ARGUMENTS FROM USER IN RIB
	RENA37:	MOVE	T1,.USMBF	;LOC OF MON BUF
 WIT
	IFN FTWATCH,<
		PUSH	P,M		;SAVE ADDR OF ALC
	>
		PUSHJ	P,SETVAL	;STORE ARGUMENTS FROM USER IN RIB
	IFN FTWATCH,<
		POP	P,M		;POINT AT ERROR CODE
		HRRI	M,<UUXEXT-UUXALC>(M);IN CASE PARTIAL ALLOCATION
	>
	RENA37:
	IFN FTWATCH,<
	;WE MUST DO "SET WATCH FILES" STUFF NOW WHILE
	;DEVSFD STILL POINTS TO THE RIGHT PLACE (THE NEW SFD) AND
	;WHILE THE SFD USE COUNTS ARE STILL UP
		TLNN	M,UPARAL	;PARTIAL ALLOCATION ERROR?
		TRZ	M,-1		;NO, INDICATE NO ERROR CODE
		PUSHJ	P,WCHFIL##	;TYPE SET WATCH FILES
		 CAI	"R"
		MOVSI	T1,(UP.SWF)	;LIGHT BIT SO WE DON'T DO IT AGAIN
		IORM	T1,.USBTS
	>
		MOVE	T1,.USMBF	;LOC OF MON BUF
 SUM 227536