TITLE "Z33PDEFD - Z3lib 4.0" ;================================================================= ; Copyright (C) 1989 by Jay Sage. Permission granted to ; Alpha Systems Corp. to distribute with The Libraries, Version 4 ;----------------------------------------------------------------- ; Author : Jay Sage. ; Date : ; Version : 1.0 ; Module : Z33PDEFD ; Abstract: This module contains the routine PDEFDU which puts ; the drive/user balues in BC into the CURDR and CURUSR bytes ; in the message buffer, making that directory the default. ; Revision: ;- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ; Module Entry Points PUBLIC PDEFDU ; External References EXT GETMSG ; Definitions OFFCUSR EQU 2EH ; Offset to current User in Msg Buffer .Z80 CSEG ;=============================================================== ; NAME - PDEFDU ; Entry: BC - contains the Drive (B) and User (C) to set ; Exit : - None ; Uses : - None ; Special Requirements: None ;=============================================================== PDEFDU: PUSH HL ; Preserve registers PUSH AF PUSH BC CALL GETMSG ; Get pointer to start of Message Buffer LD BC,OFFCUSR ; ..and offset to Current User Byte ADD HL,BC POP BC ; Restore DU: LD (HL),C ; Store User number from C INC HL LD (HL),B ; Store Drive from B (A=0) POP AF ; Restore rest of regs POP HL RET END