diff options
author | kaashoek <kaashoek> | 2006-08-14 21:22:13 +0000 |
---|---|---|
committer | kaashoek <kaashoek> | 2006-08-14 21:22:13 +0000 |
commit | d7b3b802f414dbf18b5e196ab1a342b19d5f7be8 (patch) | |
tree | ccbb34d956ae638d1fbcb24d850b62edb05e841a /printf.c | |
parent | bdb66433031ca96f2fd127995186623cd10c45b3 (diff) | |
download | xv6-labs-d7b3b802f414dbf18b5e196ab1a342b19d5f7be8.tar.gz xv6-labs-d7b3b802f414dbf18b5e196ab1a342b19d5f7be8.tar.bz2 xv6-labs-d7b3b802f414dbf18b5e196ab1a342b19d5f7be8.zip |
user-level programs: mkdir and rm
shell parses arguments (very simplistic)
readme version of README (sh doesn't deal with capital characters)
printf recognizes %c
nicer output format for ls
Diffstat (limited to 'printf.c')
-rw-r--r-- | printf.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -1,5 +1,6 @@ -#include "user.h" #include "types.h" +#include "stat.h" +#include "user.h" static void putc(int fd, char c) @@ -63,6 +64,9 @@ printf(int fd, char *fmt, ...) putc(fd, *s); s++; } + } else if(c == 'c'){ + putc(fd, *ap); + ap++; } else if(c == '%'){ putc(fd, c); } else { |