summaryrefslogtreecommitdiff
path: root/src/init/main.c
diff options
context:
space:
mode:
authordzwdz2022-04-14 08:34:50 +0200
committerdzwdz2022-04-14 08:34:50 +0200
commitced5298a40faf8250759c34c13c8de0f62924d19 (patch)
treef328c1ab46798a2d24ddde98bfb59dbfa62286cb /src/init/main.c
parentacf27b6071884c7a0939f26f47d3895d134f5088 (diff)
init/fs: fix `fs_dir_inject`
the loop wasn't bounder, so was copying garbage - including multiple null bytes also, the trailing slash was appended even if the injected path didn't have one
Diffstat (limited to 'src/init/main.c')
-rw-r--r--src/init/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/init/main.c b/src/init/main.c
index b5ef22f..3460417 100644
--- a/src/init/main.c
+++ b/src/init/main.c
@@ -22,11 +22,11 @@ int main(void) {
// allocate bss
_syscall_memflag(&_bss_start, &_bss_end - &_bss_start, MEMFLAG_PRESENT);
- MOUNT("/init", tar_driver(&_initrd));
+ MOUNT("/init/", tar_driver(&_initrd));
MOUNT("/keyboard", ps2_drv());
MOUNT("/vga_tty", ansiterm_drv());
- MOUNT("/bind", fs_passthru(NULL));
+ MOUNT("/bind/", fs_passthru(NULL));
if (!_syscall_fork()) {
__stdin = __stdout = _syscall_open(argify("/com1"));