mirror of
https://github.com/Tom-on64/kern.git
synced 2026-11-04 10:33:12 +00:00
MAJOR RESTRUCTURE
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include <syscalls/syscalls.h>
|
||||
#include <screen/tty.h>
|
||||
#include <cpu/isr.h>
|
||||
#include <stddef.h>
|
||||
|
||||
int sys_write(intFrame_t* iframe) {
|
||||
int fd = iframe->ebx;
|
||||
void* buf = (void*)iframe->ecx;
|
||||
size_t len = iframe->edx;
|
||||
|
||||
if (fd == 1) {
|
||||
return consoleWrite(buf, len);
|
||||
} else { return -1; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user