Skip to content
Snippets Groups Projects
Commit 4e5c1a8a authored by Byron Lathi's avatar Byron Lathi
Browse files

add shell

parent aa0de544
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@ CFLAGS += -Wall -nostdlib -ffreestanding -m32 -g
LDFLAGS += -nostdlib -ffreestanding -m32
CC=i686-elf-gcc
SRC = hello exectest read
SRC = hello exectest read shell
.SUFFIXES:
......
#include "syscall.h"
int main()
{
uint8_t test[64];
int ret;
while (1){
sys_read(0, test, 64);
ret = sys_exec(test);
if (ret) {
sys_write(1, "Error.\n", 7);
}
}
return -1;
}
\ No newline at end of file
......@@ -117,7 +117,7 @@ void entry(unsigned long magic, unsigned long addr) {
ata_read_sectors(ATA_MASTER, 0, 1, mbr.data);
ext2_init(mbr.partitions[0].lba_start);
int32_t error = sys_exec((uint8_t*)"/Programs/bin/exectest");
int32_t error = sys_exec((uint8_t*)"/Programs/bin/shell");
if (error) {
printf("Error executing file: %d\n", error);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment