summaryrefslogtreecommitdiff
path: root/LibC/stdio.cpp
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2018-10-23 10:12:50 +0200
committerAndreas Kling <awesomekling@gmail.com>2018-10-23 10:12:50 +0200
commitfe237ee215fafd2012e6f4e5da88e3c2b8f9d33d (patch)
tree9c88982f0717bd2ee465d19ccb967dd1b27de91f /LibC/stdio.cpp
parent72514c8b97891a3a032ae7b3003064ac9cf554e7 (diff)
downloadserenity-fe237ee215fafd2012e6f4e5da88e3c2b8f9d33d.zip
Lots of hacking:
- Turn Keyboard into a CharacterDevice (85,1) at /dev/keyboard. - Implement MM::unmapRegionsForTask() and MM::unmapRegion() - Save SS correctly on interrupt. - Add a simple Spawn syscall for launching another process. - Move a bunch of IO syscall debug output behind DEBUG_IO. - Have ASSERT do a "cli" immediately when failing. This makes the output look proper every time. - Implement a bunch of syscalls in LibC. - Add a simple shell ("sh"). All it can do now is read a line of text from /dev/keyboard and then try launching the specified executable by calling spawn(). There are definitely bugs in here, but we're moving on forward.
Diffstat (limited to 'LibC/stdio.cpp')
-rw-r--r--LibC/stdio.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/LibC/stdio.cpp b/LibC/stdio.cpp
index dd5b26f9a5..31f0d14d41 100644
--- a/LibC/stdio.cpp
+++ b/LibC/stdio.cpp
@@ -141,7 +141,8 @@ extern "C" {
int putchar(int ch)
{
- return ch;
+ Syscall::invoke(Syscall::PutCharacter, ch);
+ return (byte)ch;
}
int printf(const char* fmt, ...)