Small fixes in syscall.c
This commit is contained in:
parent
e66040a0c3
commit
66b966d584
|
@ -7,18 +7,10 @@ static void print(char* buffer)
|
|||
terminal_writestring(buffer);
|
||||
}
|
||||
|
||||
static void* memcpy(void* restrict dstptr, const void* restrict srcptr, size_t size) {
|
||||
unsigned char* dst = (unsigned char*) dstptr;
|
||||
const unsigned char* src = (const unsigned char*) srcptr;
|
||||
for (size_t i = 0; i < size; i++)
|
||||
dst[i] = src[i];
|
||||
return dstptr;
|
||||
}
|
||||
|
||||
static void input(char* buffer)
|
||||
{
|
||||
while (true) {
|
||||
for (int i = 0; i < keyboard_buffer_top; i++) {
|
||||
for (size_t i = 0; i < keyboard_buffer_top; i++) {
|
||||
buffer[i] = keyboard_buffer[i];
|
||||
if (keyboard_buffer[i] == '\n') {
|
||||
buffer[keyboard_buffer_top] = 0;
|
||||
|
|
Loading…
Reference in a new issue