diff --git a/libsrc/telestrat/open.s b/libsrc/telestrat/open.s index b3b390003..8e94de311 100644 --- a/libsrc/telestrat/open.s +++ b/libsrc/telestrat/open.s @@ -1,6 +1,8 @@ - .export _open - .import addysp,popax - .importzp sp,tmp2,tmp3,tmp1 + .export _open + + .import addysp,popax + + .importzp sp,tmp2,tmp3,tmp1 .include "telestrat.inc" @@ -15,17 +17,18 @@ dey ; ...checked (it generates a c compiler warning) dey dey - beq parmok ; Branch if parameter count ok - jsr addysp ; Fix stack, throw away unused parameters + beq parmok ; Branch if parameter count ok + jsr addysp ; Fix stack, throw away unused parameters ; Parameters ok. Pop the flags and save them into tmp3 -parmok: jsr popax ; Get flagss - sta tmp3 ; save flags +parmok: + jsr popax ; Get flagss + sta tmp3 ; save flags ; Get the filename from stack and parse it. Bail out if is not ok - jsr popax ; Get name - ldy tmp3 ; Get flags again - BRK_TELEMON XOPEN ; launch primitive ROM + jsr popax ; Get name + ldy tmp3 ; Get flags again + BRK_TELEMON XOPEN ; launch primitive ROM rts .endproc diff --git a/libsrc/telestrat/read.s b/libsrc/telestrat/read.s index 85a6132eb..75766cda2 100644 --- a/libsrc/telestrat/read.s +++ b/libsrc/telestrat/read.s @@ -2,8 +2,6 @@ ; jede jede@oric.org 2017-01-22 ; - - .FEATURE c_comments,labels_without_colons,pc_assignment, loose_char_term .export _read .import popax @@ -11,7 +9,7 @@ .include "zeropage.inc" .include "telestrat.inc" -; int read (int fd, void* buf, unsigned count); +;int read (int fd, void* buf, unsigned count); .proc _read sta ptr1 ; count diff --git a/libsrc/telestrat/write.s b/libsrc/telestrat/write.s index 278c28c83..1d269887d 100644 --- a/libsrc/telestrat/write.s +++ b/libsrc/telestrat/write.s @@ -59,7 +59,7 @@ L2: ldy #0 ldx #$0D L3: - BRK_TELEMON XWR0 ; Macro + BRK_TELEMON XWR0 ; Macro inc ptr1 bne L1