PIPDEF M0005, SET DEFAULT COMMA	MACRO M1110  22-AUG-78 01:32

TABLE OF CONTENTS



     7-    1	**** PIPDEF VERSION M0005 ****

PIPDEF M0005, SET DEFAULT COMMA	MACRO M1110  22-AUG-78 01:32  PAGE 7





      1						.TITLE	PIPDEF M0005, SET DEFAULT COMMAND-PIP

						.SBTTL	**** PIPDEF VERSION M0005 ****

						.IDENT	/M0005/

      2					;

      3					; ALTERED:

      4					; BENN L. SCHREIBER	1-APR-77

      5					; COPYRIGHT   1974,  DIGITAL  EQUIPMENT  CORP.,  MAYNARD,   MASS.

      6					;

      7					; THIS SOFTWARE IS FURNISHED TO PURCHASER UNDER A LICENSE FOR USE

      8					; ON A  SINGLE COMPUTER SYSTEM AND CAN BE  COPIED (WITH INCLUSION

      9					; OF DEC'S COPYRIGHT  NOTICE) ONLY FOR USE IN SUCH SYSTEM, EXCEPT

     10					; AS MAY OTHERWISE BE PROVIDED IN WRITING BY DEC.

     11					;

     12					; THE  INFORMATION  IN THIS DOCUMENT IS SUBJECT TO CHANGE WITHOUT

     13					; NOTICE  AND  SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL

     14					; EQUIPMENT CORPORATION.

     15					;

     16					; DEC  ASSUMES NO  RESPONSIBILITY  FOR  THE  USE  OR  RELIABILITY

     17					; OF  ITS  SOFTWARE ON  EQUIPMENT WHICH  IS  NOT SUPPLIED BY DEC.

     18					;

     19					; PETER H. LIPMAN	14-MAY-74

     20					;

     21	000000					FLDSOF

     22						.MCALL	CSI$,FDOF$L,CALL,RETURN

     23	000000					CSI$			;DEFINE CSI OFSETS

     24	000000					FDOF$L			;DEFINE FDB OFFSETS LOCALLY

     25					;

     26					; SET DEFAULT DEVICE OR DIRECTORY

     27					;

     28	000000				.SETDF::

     29	000000	005767 	000000G			TST	INSPEC		;NO INPUT SPECIFIER ALLOWED

     30	000004	001010 				BNE	10$		;BRANCH IF BAD SYNTAX

     31	000006	032767 	000031 	000000G		BIT	#CS.NMF!CS.MOR!CS.WLD,OUSPEC ;ONLY DEV OR UIC ALLOWED

     32	000014	001004 				BNE	10$		;BRANCH IF BAD SYNTAX

     33	000016	032767 	000006 	000000G		BIT	#CS.DVF!CS.DIF,OUSPEC ;EXPLICIT DEV OR DIR?

     34	000024	001003 				BNE	20$		;BRANCH IF YES, OK SYNTAX

     35	000026				10$:	ERROUX	DF01		;BAD SYNTAX FOR /DFAULT SWITCH

	000026	104403 				TRAP	X

	000030	000000G				.WORD	DF01SZ

	000032	000000G				.WORD	DF01MG

     36	000034	032767 	000004 	000000G	20$:	BIT	#CS.DVF,OUSPEC	;IS USER CHANGING THE DEFAULT DEVICE?

     37	000042	001402 				BEQ	30$		;BRANCH IF NO

     38	000044					CALL	SETDEV		;YES, GO SET THE NEW DEFAULT

     39	000050	032767 	000002 	000000G	30$:	BIT	#CS.DIF,OUSPEC	;IS HE CHANGING THE DEFAULT DIRECTORY?

     40	000056	001402 				BEQ	50$		; IF EQ NO

     41	000060				40$:	CALL	SETUIC		;CHANGE THE DEFAULT UIC

     42	000064	000167 	000000G		50$:	JMP	CLOSX

PIPDEF M0005, SET DEFAULT COMMA	MACRO M1110  22-AUG-78 01:32  PAGE 8

**** PIPDEF VERSION M0005 ****



     44					;

     45					; SET DEFAULT DEVICE AND UNIT

     46					;

     47	000070	012700 	000000G		SETDEV:	MOV	#FDBOUT,R0

     48	000074	012701 	000000G			MOV	#NMBLK1,R1

     49	000100	012702 	000000G			MOV	#OFNPT,R2

     50	000104	005003 				CLR	R3

     51	000106					CALL	.PRSDV		;PARSE THE DEVICE NAME

     52	000112	103407 				BCS	20$

     53	000114	016167 	000032 	000000G		MOV	N.DVNM(R1),.DEFDV

     54	000122	016167 	000034 	000000G		MOV	N.UNIT(R1),.DEFUN

     55	000130					RETURN

     56	000132				20$:	CALL	PRSERR

     57	000136					RETURN

     58

     59					;

     60					; SET DEFAULT UIC

     61					;

     62	000140	032767 	000002 	000000G	SETUIC:	BIT	#CS.DIF,OUSPEC	;EXPLICIT DIRECTORY SPECIFIED?

     63	000146	001422 				BEQ	50$		; IF EQ THEN ERROR

     64	000150	016702 	000004G		10$:	MOV	OFNPT+N.DIRD,R2	;R2=SIZE OF DIRECTORY STRING

     65	000154	016703 	000006G			MOV	OFNPT+N.DIRD+2,R3 ;R3=ADDR OF DIRECTORY STRING

     66	000160	022702 	000000G			CMP	#DFDRSZ,R2	;IS STRING LONGER THAN SPACE ALLOCATED?

     67	000164	002413 				BLT	50$		;BRANCH IF YES

     68	000166	012701 	000000G			MOV	#DEFDIR,R1

     69	000172					CALL	MVSTRG		;MOVE STRING TO DEFAULT DIRECTORY AREA

     70	000176	016701 	000004G			MOV	OFNPT+N.DIRD,R1	;R1=SIZE

     71	000202	012702 	000000G		40$:	MOV	#DEFDIR,R2	;R2=ADR OF DEF DIR STRING

     72	000206					CALL	.WDFDR		;CALL FCS TO SET THE DEFAULT

     73	000212					RETURN

     74	000214				50$:	ERROUX	UI01		;SYNTAX ERROR

	000214	104403 				TRAP	X

	000216	000000G				.WORD	UI01SZ

	000220	000000G				.WORD	UI01MG

     75

     76					;

     77					;

     78		000001 				.END

PIPDEF M0005, SET DEFAULT COMMA	MACRO M1110  22-AUG-78 01:32  PAGE 8-1

SYMBOL TABLE



AB.CDT  000105   	C.MKW2= 000026   	F.EFN = 000050   	F.UNIT= 000136   	R$$DPB= 000001

AB.CHU  000064   	C.SIZE= 000054   	F.EOBB= 000032   	F.URBD= 000020   	R$$DYM= 000001

AB.EXP  000122   	C.STAT= 000001   	F.ERR = 000052   	F.VBN = 000064   	R$$EIS= 000000

AB.FNU  000000   	C.SWAD= 000022   	F.FACC= 000043   	F.VBSZ= 000060   	R$$VMS= 000001

AB.FP   000062   	C.TYPR= 000000   	F.FFBY= 000014   	INSPEC= ****** GX	R$$11M= 000001

AB.FSQ  000002   	DEFDIR= ****** GX	F.FNAM= 000110   	MVSTRG= ****** GX	SETDEV  000070R

AB.GC   000061   	DFDRSZ= ****** GX	F.FNB = 000102   	NB.NXD= 020000   	SETUIC  000140R

AB.NAM  000006   	DF01MG= ****** GX	F.FTYP= 000116   	NB.WLV= 010000   	S.APPD= 000010

AB.PC   000060   	DF01SZ= ****** GX	F.FVER= 000120   	NMBLK1= ****** GX	S.FATT= 000016

AB.RDT  000070   	FDBOUT= ****** GX	F.HIBK= 000004   	N.DEVD= 000000   	S.FDB = 000140

AB.REV  000066   	F.ACTL= 000076   	F.LUN = 000042   	N.DID = 000024   	S.FIDS= 000014

AB.UAT  000020   	F.ALOC= 000040   	F.MBCT= 000054   	N.DIRD= 000004   	S.FNAM= 000006

CLOSX = ****** GX	F.BBFS= 000062   	F.MBC1= 000055   	N.DVNM= 000032   	S.FNB = 000036

CS.DIF= 000002   	F.BDB = 000070   	F.MBFG= 000056   	N.FID = 000000   	S.FNBW= 000017

CS.DVF= 000004   	F.BGBC= 000057   	F.NRBD= 000024   	N.FLID= 000016   	S.FNTY= 000004

CS.EQU= 000040   	F.BKDN= 000026   	F.NREC= 000030   	N.FNAM= 000006   	S.FTYP= 000002

CS.INP= 000001   	F.BKDS= 000020   	F.OVBS= 000030   	N.FNMD= 000010   	S.NFEN= 000020

CS.MOR= 000020   	F.BKEF= 000050   	F.RACC= 000016   	N.FTYP= 000014   	UI01MG= ****** GX

CS.NMF= 000001   	F.BKP1= 000051   	F.RATT= 000001   	N.FVER= 000016   	UI01SZ= ****** GX

CS.OUT= 000002   	F.BKST= 000024   	F.RCNM= 000034   	N.NEXT= 000022   	X     = 000003

CS.WLD= 000010   	F.BKVB= 000064   	F.RCTL= 000017   	N.SPEC= 000014   	.DEFDV= ****** GX

C.CMLD= 000002   	F.CHR = 000075   	F.RSIZ= 000002   	N.STAT= 000020   	.DEFUN= ****** GX

C.DEVD= 000006   	F.CNTG= 000034   	F.RTYP= 000000   	N.UNIT= 000034   	.PRSDV= ****** GX

C.DIRD= 000012   	F.DFNB= 000046   	F.SEQN= 000100   	OFNPT = ****** GX	.SETDF  000000RG

C.DSDS= 000006   	F.DSPT= 000044   	F.SPDV= 000072   	OUSPEC= ****** GX	.WDFDR= ****** GX

C.FILD= 000016   	F.DVNM= 000134   	F.SPUN= 000074   	O$$DS2= 000001   	...TPC= 000140

C.MKW1= 000024   	F.EFBK= 000010   	F.STBK= 000036   	PRSERR= ****** GX



. ABS.	000131	   000

      	000222	   001

ERRORS DETECTED:  0



VIRTUAL MEMORY USED:  3729 WORDS  ( 15 PAGES)

DYNAMIC MEMORY:  4884 WORDS  ( 18 PAGES)

ELAPSED TIME:  00:00:15

OBJ$:PIPDEF,LIS$:PIPDEF/-SP=SRC$:PIPMAC,PIPDEF

