; ;Patch to allow Submit to execute .SUB files from different ;user numbers. The user number is passed in the SCB from the CCP. ;The SYSINxx.$$$ file is always created in user 0 of the submit drive ; bdos equ 5 getscb equ 3e4h read equ 38fh open equ 35ch start equ 278h org 103h mvi c,3ah call getscb ;get address of System control block mvi l,0e0h ;point to BDOS user number shld useraddr mov a,m ;get current user sta subuser ;save it xra a ;set to zero mov m,a ;set user number to zero mvi l,0a4h ;point to submit user number mov a,m ani 1fh ;strip of high bits jz start ;jump if no sub user dcr a ;adjust sta subuser ;save submit user jmp start testuser: lda subuser ;get submit file user lhld useraddr ;get user number addr in SCB mov m,a ;set the BDOS user # push h call bdos ;do the function pop b push psw ;save return code xra a ;get current user # stax b ;set current BDOS user # pop psw ret useraddr: dw 0 subuser: db 0 org open call testuser org read call testuser end