1: /
2: /
3:
4: / openr, openw--
5: /
6: / call open(r|w) (string, iunit)
7: / or,
8: / call open(r|w) (argno, iunit)
9: / where argno is an argument number (0 is command name)
10:
11: .globl openr.
12: .globl openw.
13:
14: .globl utable
15: .globl btable
16: .globl ftable
17: .globl getbuf
18: .globl fopen
19: .globl fcreat
20:
21: openr.: temp
22: .+2
23: mov pc,-(sp)
24: br 1f
25:
26: openw.: temp
27: .+2
28: clr -(sp)
29: 1:
30: mov 4(r3),r1
31: mov 2(r1),r1
32: jsr r5,chkunit
33: tstb utable(r1)
34: beq 1f
35: jsr r5,rerr; 101.
36: sys exit
37: 1:
38: jsr r5,getbuf
39: mov 2(r3),r0
40: mov 2(r0),r0
41: cmp r0,$32.
42: bhi 1f
43: cmp r0,*argp
44: bhi err
45: asl r0
46: add argp,r0
47: br 2f
48: 1:
49: tst (sp)+
50: beq 1f
51: movb $1,utable(r1)
Defined functions
openr.
declared in line
11; defined in line
21; used 1 times
openw.
declared in line
12; defined in line
26; used 1 times