take care of proper exit status
This commit is contained in:
parent
ec3d8bb5aa
commit
6d9d69aebf
|
@ -275,12 +275,14 @@ lhalt:
|
||||||
pea emlast
|
pea emlast
|
||||||
bsr _Xunlink
|
bsr _Xunlink
|
||||||
testen (sp)+
|
testen (sp)+
|
||||||
blt halt
|
beq 1f
|
||||||
|
testen (sp)+ ! ignore result
|
||||||
|
1:
|
||||||
mov #0x1B6,-(sp)
|
mov #0x1B6,-(sp)
|
||||||
pea emlast
|
pea emlast
|
||||||
bsr _Xcreat
|
bsr _Xcreat
|
||||||
testen (sp)+
|
testen (sp)+
|
||||||
blt halt
|
bne halt
|
||||||
mov (sp)+,d6 !d6 contains file descriptor
|
mov (sp)+,d6 !d6 contains file descriptor
|
||||||
cmp.l #-1,linused-4 !test if buffer is fully used
|
cmp.l #-1,linused-4 !test if buffer is fully used
|
||||||
beq 0f
|
beq 0f
|
||||||
|
@ -294,7 +296,7 @@ lhalt:
|
||||||
mov d6,-(sp)
|
mov d6,-(sp)
|
||||||
bsr _Xwrite
|
bsr _Xwrite
|
||||||
testen (sp)+
|
testen (sp)+
|
||||||
blt halt
|
bne halt
|
||||||
add.l #4,sp
|
add.l #4,sp
|
||||||
bra 9f
|
bra 9f
|
||||||
2: move.l a1,-(sp)
|
2: move.l a1,-(sp)
|
||||||
|
@ -303,7 +305,7 @@ lhalt:
|
||||||
mov d6,-(sp)
|
mov d6,-(sp)
|
||||||
bsr _Xwrite
|
bsr _Xwrite
|
||||||
testen (sp)+
|
testen (sp)+
|
||||||
blt halt
|
bne halt
|
||||||
add.l #4,sp
|
add.l #4,sp
|
||||||
move.l (sp)+,a1
|
move.l (sp)+,a1
|
||||||
move.l (a1),d7
|
move.l (a1),d7
|
||||||
|
@ -318,7 +320,9 @@ lhalt:
|
||||||
move.l d7,-(sp)
|
move.l d7,-(sp)
|
||||||
mov d6,-(sp)
|
mov d6,-(sp)
|
||||||
bsr _Xwrite
|
bsr _Xwrite
|
||||||
add.l wrd+4,sp
|
testen (sp)+
|
||||||
|
bne halt
|
||||||
|
add.l 4,sp
|
||||||
move.l (sp)+,a1
|
move.l (sp)+,a1
|
||||||
4: move.l (a1),d1 !next print line numbers
|
4: move.l (a1),d1 !next print line numbers
|
||||||
lea mess3,a0
|
lea mess3,a0
|
||||||
|
@ -329,7 +333,7 @@ lhalt:
|
||||||
mov d6,-(sp)
|
mov d6,-(sp)
|
||||||
bsr _Xwrite
|
bsr _Xwrite
|
||||||
testen (sp)+
|
testen (sp)+
|
||||||
blt halt
|
bne halt
|
||||||
add.l #4,sp
|
add.l #4,sp
|
||||||
move.l (sp)+,a1
|
move.l (sp)+,a1
|
||||||
bsr nexttab
|
bsr nexttab
|
||||||
|
@ -340,6 +344,7 @@ lhalt:
|
||||||
clr.l (a1)+ !skip file name
|
clr.l (a1)+ !skip file name
|
||||||
bra 4b !only new line
|
bra 4b !only new line
|
||||||
9:
|
9:
|
||||||
|
clr.l -(sp)
|
||||||
.sect .data
|
.sect .data
|
||||||
emlast: .asciz "em_last"
|
emlast: .asciz "em_last"
|
||||||
mess1: .asciz "no line processed yet\n"
|
mess1: .asciz "no line processed yet\n"
|
||||||
|
|
Loading…
Reference in a new issue