summaryrefslogtreecommitdiff
path: root/stdio.asm
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2018-06-19 00:48:26 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2018-06-19 00:48:26 -0400
commit6f7f67b1b4d1d124822e29ae669f1e8107de8f1b (patch)
treed37889b49f8e7c4af554a01649c93fe3705dc6e8 /stdio.asm
parent74d39e30d2966c5f62f55a781d0428b0308fff82 (diff)
downloadminos-6f7f67b1b4d1d124822e29ae669f1e8107de8f1b.tar.gz
Implement TAB
Diffstat (limited to 'stdio.asm')
-rw-r--r--stdio.asm8
1 files changed, 8 insertions, 0 deletions
diff --git a/stdio.asm b/stdio.asm
index 23d2ac9..161d1a3 100644
--- a/stdio.asm
+++ b/stdio.asm
@@ -218,6 +218,9 @@ printf:
.parse_control:
lodsb ; get next byte
+ cmp al, 't' ; TAB
+ je .do_TAB
+
cmp al, 'n' ; new line
je .do_LF
@@ -226,6 +229,11 @@ printf:
jmp .do_default
+ .do_TAB:
+ mov ax, ASCII_TAB
+ call putc
+ jmp .main_string
+
.do_LF:
mov ax, ASCII_CR ; home the line
call putc