324
|
1 ********************************************************************
|
|
2 * error - show error messages
|
|
3 *
|
|
4 * $Id$
|
|
5 *
|
|
6 * Ed. Comments Who YY/MM/DD
|
|
7 * ------------------------------------------------------------------
|
|
8 * 2 From Tandy OS-9 Level Two Vr. 02.00.01
|
|
9
|
|
10 nam error
|
|
11 ttl show error messages
|
|
12
|
|
13 * Disassembled 02/07/06 13:09:55 by Disasm v1.6 (C) 1988 by RML
|
|
14
|
|
15 ifp1
|
|
16 use defsfile
|
|
17 endc
|
|
18
|
|
19 tylg set Prgrm+Objct
|
|
20 atrv set ReEnt+rev
|
|
21 rev set $01
|
|
22 edition set 2
|
|
23
|
|
24 L0000 mod eom,name,tylg,atrv,start,size
|
|
25
|
924
|
26 org 0
|
324
|
27 u0000 rmb 1
|
|
28 u0001 rmb 1
|
|
29 u0002 rmb 1
|
|
30 u0003 rmb 1
|
|
31 u0004 rmb 1
|
|
32 u0005 rmb 12
|
|
33 u0011 rmb 15
|
|
34 u0020 rmb 55
|
|
35 u0057 rmb 2
|
|
36 u0059 rmb 2
|
|
37 u005B rmb 42
|
|
38 u0085 rmb 13
|
|
39 u0092 rmb 25
|
|
40 u00AB rmb 49
|
|
41 u00DC rmb 2
|
|
42 u00DE rmb 58
|
|
43 u0118 rmb 1
|
|
44 u0119 rmb 3
|
|
45 u011C rmb 912
|
|
46 size equ .
|
|
47
|
|
48 name fcs /error/
|
|
49 fcb edition
|
|
50
|
|
51 L0013 fcb $A6 &
|
|
52 fcb $A0
|
|
53 fcb $A7 '
|
|
54 fcb $C0 @
|
|
55 fcb $30 0
|
|
56 fcb $1F
|
|
57 fcb $26 &
|
|
58 fcb $F8 x
|
|
59 fcb $39 9
|
|
60 start equ *
|
|
61 pshs y
|
|
62 pshs u
|
|
63 clra
|
|
64 clrb
|
|
65 L0022 sta ,u+
|
|
66 decb
|
|
67 bne L0022
|
|
68 ldx ,s
|
|
69 leau ,x
|
|
70 leax >$012C,x
|
|
71 pshs x
|
|
72 leay >L064C,pcr
|
|
73 ldx ,y++
|
|
74 beq L003D
|
|
75 bsr L0013
|
|
76 ldu $02,s
|
|
77 L003D leau >u0057,u
|
|
78 ldx ,y++
|
|
79 beq L0048
|
|
80 bsr L0013
|
|
81 clra
|
|
82 L0048 cmpu ,s
|
|
83 beq L0051
|
|
84 sta ,u+
|
|
85 bra L0048
|
|
86 L0051 ldu $02,s
|
|
87 ldd ,y++
|
|
88 beq L005E
|
|
89 leax >L0000,pcr
|
|
90 lbsr L0161
|
|
91 L005E ldd ,y++
|
|
92 beq L0067
|
|
93 leax ,u
|
|
94 lbsr L0161
|
|
95 L0067 leas $04,s
|
|
96 puls x
|
|
97 stx >u011C,u
|
|
98 sty >u00DC,u
|
|
99 ldd #$0001
|
|
100 std >u0118,u
|
|
101 leay >u00DE,u
|
|
102 leax ,s
|
|
103 lda ,x+
|
|
104 L0083 ldb >u0119,u
|
|
105 cmpb #$1D
|
|
106 beq L00DF
|
|
107 L008B cmpa #$0D
|
|
108 beq L00DF
|
|
109 cmpa #$20
|
|
110 beq L0097
|
|
111 cmpa #$2C
|
|
112 bne L009B
|
|
113 L0097 lda ,x+
|
|
114 bra L008B
|
|
115 L009B cmpa #$22
|
|
116 beq L00A3
|
|
117 cmpa #$27
|
|
118 bne L00C1
|
|
119 L00A3 stx ,y++
|
|
120 inc >u0119,u
|
|
121 pshs a
|
|
122 L00AB lda ,x+
|
|
123 cmpa #$0D
|
|
124 beq L00B5
|
|
125 cmpa ,s
|
|
126 bne L00AB
|
|
127 L00B5 puls b
|
|
128 clr -$01,x
|
|
129 cmpa #$0D
|
|
130 beq L00DF
|
|
131 lda ,x+
|
|
132 bra L0083
|
|
133 L00C1 leax -$01,x
|
|
134 stx ,y++
|
|
135 leax $01,x
|
|
136 inc >u0119,u
|
|
137 L00CB cmpa #$0D
|
|
138 beq L00DB
|
|
139 cmpa #$20
|
|
140 beq L00DB
|
|
141 cmpa #$2C
|
|
142 beq L00DB
|
|
143 lda ,x+
|
|
144 bra L00CB
|
|
145 L00DB clr -$01,x
|
|
146 bra L0083
|
|
147 L00DF leax >u00DC,u
|
|
148 pshs x
|
|
149 ldd >u0118,u
|
|
150 pshs b,a
|
|
151 leay ,u
|
|
152 bsr L00F9
|
|
153 lbsr L017B
|
|
154 clr ,-s
|
|
155 clr ,-s
|
|
156 lbsr L063F
|
|
157 L00F9 leax >$012C,y
|
|
158 stx >$0126,y
|
|
159 sts >$011A,y
|
|
160 sts >$0128,y
|
|
161 ldd #$FF82
|
|
162 L010E leax d,s
|
|
163 cmpx >$0128,y
|
|
164 bcc L0120
|
|
165 cmpx >$0126,y
|
|
166 bcs L013A
|
|
167 stx >$0128,y
|
|
168 L0120 rts
|
|
169 L0121 fcc "**** STACK OVERFLOW ****"
|
|
170 fcb C$CR
|
|
171 L013A leax <L0121,pcr
|
|
172 ldb #$CF
|
|
173 pshs b
|
|
174 lda #$02
|
|
175 ldy #$0064
|
|
176 L0147 os9 I$WritLn
|
|
177 clr ,-s
|
|
178 lbsr L0645
|
|
179 L014F ldd >$011A,y
|
|
180 subd >$0128,y
|
|
181 rts
|
|
182 ldd >$0128,y
|
|
183 subd >$0126,y
|
|
184 L0160 rts
|
|
185 L0161 pshs x
|
|
186 leax d,y
|
|
187 leax d,x
|
|
188 pshs x
|
|
189 L0169 ldd ,y++
|
|
190 leax d,u
|
|
191 ldd ,x
|
|
192 addd $02,s
|
|
193 std ,x
|
|
194 cmpy ,s
|
|
195 bne L0169
|
|
196 leas $04,s
|
|
197 L017A rts
|
|
198 L017B pshs u
|
|
199 ldd #$FFB6
|
|
200 lbsr L010E
|
|
201 ldd $04,s
|
|
202 cmpd #$0002
|
|
203 bge L01AD
|
|
204 bra L01A6
|
|
205 L018D ldd #$0050
|
|
206 pshs b,a
|
|
207 ldx <u0001
|
|
208 leax $02,x
|
|
209 stx <u0001
|
|
210 ldd -$02,x
|
|
211 pshs b,a
|
|
212 ldd #$0002
|
|
213 pshs b,a
|
|
214 lbsr L05BA
|
|
215 leas $06,s
|
|
216 L01A6 ldd <u0001
|
|
217 cmpd <u0003
|
|
218 bcs L018D
|
|
219 L01AD ldd #$0001
|
|
220 pshs b,a
|
|
221 leax >L03E1,pcr
|
|
222 pshs x
|
|
223 lbsr L04F4
|
|
224 leas $04,s
|
|
225 std <u0005
|
|
226 cmpd #$FFFF
|
|
227 bne L01E5
|
|
228 ldd #$001C
|
|
229 pshs b,a
|
|
230 leax >L03F0,pcr
|
|
231 pshs x
|
|
232 lbsr L0358
|
|
233 leas $04,s
|
|
234 bra L01E5
|
|
235 L01D7 ldx $06,s
|
|
236 leax $02,x
|
|
237 stx $06,s
|
|
238 ldd ,x
|
|
239 pshs b,a
|
|
240 bsr L01F8
|
|
241 leas $02,s
|
|
242 L01E5 ldd $04,s
|
|
243 addd #$FFFF
|
|
244 std $04,s
|
|
245 bne L01D7
|
|
246 ldd <u0005
|
|
247 pshs b,a
|
|
248 lbsr L0503
|
|
249 lbra L038E
|
|
250 L01F8 pshs u
|
|
251 ldd #$FFA8
|
|
252 lbsr L010E
|
|
253 leas -$0C,s
|
|
254 clra
|
|
255 clrb
|
|
256 std ,s
|
|
257 clra
|
|
258 clrb
|
|
259 pshs b,a
|
|
260 clra
|
|
261 clrb
|
|
262 pshs b,a
|
|
263 pshs b,a
|
|
264 ldd <u0005
|
|
265 pshs b,a
|
|
266 lbsr L05CA
|
|
267 leas $08,s
|
|
268 lbra L02E4
|
|
269 L021C clra
|
|
270 clrb
|
|
271 std $04,s
|
|
272 std $02,s
|
|
273 ldu <$10,s
|
|
274 bra L0229
|
|
275 L0227 leau u0001,u
|
|
276 L0229 ldb ,u
|
|
277 cmpb #$30
|
|
278 beq L0227
|
|
279 stu $08,s
|
|
280 leax >$0007,y
|
|
281 stx $0A,s
|
|
282 bra L026C
|
|
283 L0239 ldb ,u
|
|
284 sex
|
|
285 leax >$005C,y
|
|
286 leax d,x
|
|
287 ldb ,x
|
|
288 clra
|
|
289 andb #$08
|
|
290 beq L0265
|
|
291 ldb ,u+
|
|
292 sex
|
|
293 pshs b,a
|
|
294 ldx $0C,s
|
|
295 leax $01,x
|
|
296 stx $0C,s
|
|
297 ldb -$01,x
|
|
298 sex
|
|
299 cmpd ,s++
|
|
300 beq L026C
|
|
301 ldd $04,s
|
|
302 addd #$0001
|
|
303 std $04,s
|
|
304 bra L026C
|
|
305 L0265 ldd $02,s
|
|
306 addd #$0001
|
|
307 std $02,s
|
|
308 L026C ldb ,u
|
|
309 beq L0278
|
|
310 ldd $04,s
|
|
311 bne L0278
|
|
312 ldd $02,s
|
|
313 beq L0239
|
|
314 L0278 ldd $02,s
|
|
315 beq L02B6
|
|
316 ldd $08,s
|
|
317 pshs b,a
|
|
318 lbsr L045E
|
|
319 std ,s
|
|
320 ldd $0A,s
|
|
321 pshs b,a
|
|
322 ldd #$0002
|
|
323 pshs b,a
|
|
324 lbsr L05A1
|
|
325 leas $06,s
|
|
326 ldd #$0019
|
|
327 pshs b,a
|
|
328 leax >L040B,pcr
|
|
329 pshs x
|
|
330 ldd #$0002
|
|
331 pshs b,a
|
|
332 lbsr L05BA
|
|
333 leas $06,s
|
|
334 ldd $04,s
|
|
335 addd #$0001
|
|
336 std $04,s
|
|
337 ldd ,s
|
|
338 addd #$0001
|
|
339 std ,s
|
|
340 L02B6 ldb [<$0A,s]
|
|
341 cmpb #$20
|
|
342 beq L02C4
|
|
343 ldd $04,s
|
|
344 addd #$0001
|
|
345 std $04,s
|
|
346 L02C4 ldd $04,s
|
|
347 bne L02E4
|
|
348 ldd #$0050
|
|
349 pshs b,a
|
|
350 leax >$0007,y
|
|
351 pshs x
|
|
352 ldd #$0001
|
|
353 pshs b,a
|
|
354 lbsr L05BA
|
|
355 leas $06,s
|
|
356 ldd ,s
|
|
357 addd #$0001
|
|
358 std ,s
|
|
359 L02E4 ldd #$0050
|
|
360 pshs b,a
|
|
361 leax >$0007,y
|
|
362 pshs x
|
|
363 ldd <u0005
|
|
364 pshs b,a
|
|
365 lbsr L0591
|
|
366 leas $06,s
|
|
367 std -$02,s
|
|
368 ble L0301
|
|
369 ldd #$0001
|
|
370 bra L0303
|
|
371 L0301 clra
|
|
372 clrb
|
|
373 L0303 std $06,s
|
|
374 beq L030D
|
|
375 ldd ,s
|
|
376 lbeq L021C
|
|
377 L030D ldd $06,s
|
|
378 cmpd #$FFFF
|
|
379 bne L0324
|
|
380 ldd #$001C
|
|
381 pshs b,a
|
|
382 leax >L0423,pcr
|
|
383 pshs x
|
|
384 bsr L0358
|
|
385 leas $04,s
|
|
386 L0324 ldd ,s
|
|
387 bne L0354
|
|
388 ldd $08,s
|
|
389 pshs b,a
|
|
390 lbsr L045E
|
|
391 std ,s
|
|
392 ldd $0A,s
|
|
393 pshs b,a
|
|
394 ldd #$0001
|
|
395 pshs b,a
|
|
396 lbsr L05A1
|
|
397 leas $06,s
|
|
398 ldd #$0019
|
|
399 pshs b,a
|
|
400 leax >L043E,pcr
|
|
401 pshs x
|
|
402 ldd #$0001
|
|
403 pshs b,a
|
|
404 lbsr L05BA
|
|
405 leas $06,s
|
|
406 L0354 leas $0C,s
|
|
407 puls pc,u
|
|
408 L0358 pshs u
|
|
409 ldd #$FFB6
|
|
410 lbsr L010E
|
|
411 ldd #$0007
|
|
412 pshs b,a
|
|
413 leax >L0456,pcr
|
|
414 pshs x
|
|
415 ldd #$0002
|
|
416 pshs b,a
|
|
417 lbsr L05A1
|
|
418 leas $06,s
|
|
419 ldd $06,s
|
|
420 pshs b,a
|
|
421 ldd $06,s
|
|
422 pshs b,a
|
|
423 ldd #$0002
|
|
424 pshs b,a
|
|
425 lbsr L05BA
|
|
426 leas $06,s
|
|
427 clra
|
|
428 clrb
|
|
429 pshs b,a
|
|
430 lbsr L063F
|
|
431 L038E leas $02,s
|
|
432 puls pc,u
|
|
433 fcc "Error errno [errno...]"
|
|
434 fcb C$CR
|
|
435 fcb $00
|
|
436 fcc "Usage: returns error message for given error numbers"
|
|
437 fcb C$CR
|
|
438 fcb $00
|
|
439 L03E1 fcc "/dd/sys/errmsg"
|
|
440 fcb $00
|
|
441 L03F0 fcc "can't open /dd/sys/errmsg"
|
|
442 fcb C$CR
|
|
443 fcb $00
|
|
444 L040B fcc " : not an error number"
|
|
445 fcb C$CR
|
|
446 fcb $00
|
|
447 L0423 fcc "error reading errmsg file"
|
|
448 fcb C$CR
|
|
449 fcb $00
|
|
450 L043E fcc " : not an error number"
|
|
451 fcb C$CR
|
|
452 fcb $00
|
|
453 L0456 fcc "error: "
|
|
454 fcb $00
|
|
455
|
|
456 L045E pshs u
|
|
457 ldu $04,s
|
|
458 L0462 ldb ,u+
|
|
459 bne L0462
|
|
460 tfr u,d
|
|
461 subd $04,s
|
|
462 addd #$FFFF
|
|
463 puls pc,u
|
|
464 pshs u
|
|
465 ldu $06,s
|
|
466 L0473 leas -$02,s
|
|
467 ldd $06,s
|
|
468 std ,s
|
|
469 L0479 ldb ,u+
|
|
470 ldx ,s
|
|
471 L047D leax $01,x
|
|
472 stx ,s
|
|
473 stb -$01,x
|
|
474 bne L0479
|
|
475 bra L04AE
|
|
476 pshs u
|
|
477 ldu $06,s
|
|
478 leas -$02,s
|
|
479 ldd $06,s
|
|
480 std ,s
|
|
481 L0491 ldx ,s
|
|
482 leax $01,x
|
|
483 stx ,s
|
|
484 ldb -$01,x
|
|
485 bne L0491
|
|
486 ldd ,s
|
|
487 addd #$FFFF
|
|
488 std ,s
|
|
489 L04A2 ldb ,u+
|
|
490 ldx ,s
|
|
491 leax $01,x
|
|
492 stx ,s
|
|
493 stb -$01,x
|
|
494 bne L04A2
|
|
495 L04AE ldd $06,s
|
|
496 L04B0 leas $02,s
|
|
497 puls pc,u
|
|
498 pshs u
|
|
499 ldu $04,s
|
|
500 bra L04CA
|
|
501 L04BA ldx $06,s
|
|
502 leax $01,x
|
|
503 stx $06,s
|
|
504 ldb -$01,x
|
|
505 bne L04C8
|
|
506 clra
|
|
507 clrb
|
|
508 puls pc,u
|
|
509 L04C8 leau u0001,u
|
|
510 L04CA ldb ,u
|
|
511 sex
|
|
512 pshs b,a
|
|
513 ldb [<$08,s]
|
|
514 sex
|
|
515 cmpd ,s++
|
|
516 beq L04BA
|
|
517 ldb [<$06,s]
|
|
518 sex
|
|
519 pshs b,a
|
|
520 ldb ,u
|
|
521 sex
|
|
522 subd ,s++
|
|
523 puls pc,u
|
|
524 ldx $02,s
|
|
525 lda $05,s
|
|
526 os9 I$Open
|
|
527 bcs L04F1
|
|
528 os9 I$Close
|
|
529 L04F1 lbra L063A
|
|
530 L04F4 ldx $02,s
|
|
531 lda $05,s
|
|
532 os9 I$Open
|
|
533 lbcs L0631
|
|
534 tfr a,b
|
|
535 clra
|
|
536 rts
|
|
537 L0503 lda $03,s
|
|
538 os9 I$Close
|
|
539 lbra L063A
|
|
540 ldx $02,s
|
|
541 ldb $05,s
|
|
542 os9 I$MakDir
|
|
543 lbra L063A
|
|
544 ldx $02,s
|
|
545 lda $05,s
|
|
546 tfr a,b
|
|
547 andb #$24
|
|
548 orb #$0B
|
|
549 os9 I$Create
|
|
550 bcs L0528
|
|
551 L0524 tfr a,b
|
|
552 clra
|
|
553 rts
|
|
554 L0528 cmpb #$DA
|
|
555 lbne L0631
|
|
556 lda $05,s
|
|
557 bita #$80
|
|
558 lbne L0631
|
|
559 anda #$07
|
|
560 ldx $02,s
|
|
561 os9 I$Open
|
|
562 lbcs L0631
|
|
563 pshs u,a
|
|
564 ldx #$0000
|
|
565 leau ,x
|
|
566 ldb #$02
|
|
567 os9 I$SetStt
|
|
568 puls u,a
|
|
569 bcc L0524
|
|
570 pshs b
|
|
571 os9 I$Close
|
|
572 puls b
|
|
573 lbra L0631
|
|
574 ldx $02,s
|
|
575 os9 I$Delete
|
|
576 lbra L063A
|
|
577 lda $03,s
|
|
578 os9 I$Dup
|
|
579 lbcs L0631
|
|
580 tfr a,b
|
|
581 clra
|
|
582 rts
|
|
583 pshs y
|
|
584 ldx $06,s
|
|
585 lda $05,s
|
|
586 ldy $08,s
|
|
587 pshs y
|
|
588 os9 I$Read
|
|
589 L057E bcc L058D
|
|
590 cmpb #$D3
|
|
591 bne L0588
|
|
592 clra
|
|
593 clrb
|
|
594 puls pc,y,x
|
|
595 L0588 puls y,x
|
|
596 lbra L0631
|
|
597 L058D tfr y,d
|
|
598 puls pc,y,x
|
|
599 L0591 pshs y
|
|
600 lda $05,s
|
|
601 ldx $06,s
|
|
602 ldy $08,s
|
|
603 pshs y
|
|
604 os9 I$ReadLn
|
|
605 bra L057E
|
|
606 L05A1 pshs y
|
|
607 ldy $08,s
|
|
608 beq L05B6
|
|
609 lda $05,s
|
|
610 ldx $06,s
|
|
611 os9 I$Write
|
|
612 L05AF bcc L05B6
|
|
613 puls y
|
|
614 lbra L0631
|
|
615 L05B6 tfr y,d
|
|
616 puls pc,y
|
|
617 L05BA pshs y
|
|
618 ldy $08,s
|
|
619 beq L05B6
|
|
620 lda $05,s
|
|
621 ldx $06,s
|
|
622 os9 I$WritLn
|
|
623 bra L05AF
|
|
624 L05CA pshs u
|
|
625 ldd $0A,s
|
|
626 bne L05D8
|
|
627 ldu #$0000
|
|
628 ldx #$0000
|
|
629 bra L060C
|
|
630 L05D8 cmpd #$0001
|
|
631 beq L0603
|
|
632 cmpd #$0002
|
|
633 beq L05F8
|
|
634 ldb #$F7
|
|
635 L05E6 clra
|
|
636 std >$012A,y
|
|
637 ldd #$FFFF
|
|
638 leax >$011E,y
|
|
639 std ,x
|
|
640 std $02,x
|
|
641 puls pc,u
|
|
642 L05F8 lda $05,s
|
|
643 ldb #$02
|
|
644 os9 I$GetStt
|
|
645 bcs L05E6
|
|
646 bra L060C
|
|
647 L0603 lda $05,s
|
|
648 ldb #$05
|
|
649 os9 I$GetStt
|
|
650 bcs L05E6
|
|
651 L060C tfr u,d
|
|
652 addd $08,s
|
|
653 std >$0120,y
|
|
654 tfr d,u
|
|
655 tfr x,d
|
|
656 adcb $07,s
|
|
657 adca $06,s
|
|
658 bmi L05E6
|
|
659 tfr d,x
|
|
660 std >$011E,y
|
|
661 lda $05,s
|
|
662 os9 I$Seek
|
|
663 bcs L05E6
|
|
664 leax >$011E,y
|
|
665 puls pc,u
|
|
666 L0631 clra
|
|
667 std >$012A,y
|
|
668 ldd #$FFFF
|
|
669 rts
|
|
670 L063A bcs L0631
|
|
671 clra
|
|
672 clrb
|
|
673 rts
|
|
674 L063F lbsr L064A
|
|
675 lbsr L064B
|
|
676 L0645 ldd $02,s
|
|
677 os9 F$Exit
|
|
678 L064A rts
|
|
679 L064B rts
|
|
680
|
|
681 L064C fdb $0005,$0000
|
|
682 fdb $5700,$5b00,$8503,$9203,$ab00,$0101,$0101,$0101
|
|
683 fdb $0101,$0111,$1101,$1111,$0101,$0101,$0101,$0101
|
|
684 fdb $0101,$0101,$0101,$0101,$0101,$3020,$2020,$2020
|
|
685 fdb $2020,$2020,$2020,$2020,$2020,$4848,$4848,$4848
|
|
686 fdb $4848,$4848,$2020,$2020,$2020,$2042,$4242,$4242
|
|
687 fdb $4202,$0202,$0202,$0202,$0202,$0202,$0202,$0202
|
|
688 fdb $0202,$0202,$0220,$2020,$2020,$2044,$4444,$4444
|
|
689 fdb $4404,$0404,$0404,$0404,$0404,$0404,$0404,$0404
|
|
690 fdb $0404,$0404,$0420,$2020,$2001,$0002,$0059,$0057
|
|
691 fdb $0002,$0003,$0001
|
|
692
|
|
693 fcc "error"
|
|
694 fcb $00
|
|
695
|
|
696 emod
|
|
697 eom equ *
|
|
698 end
|