From a06d25b7afcd8b28ca001349634abaef87958fdc Mon Sep 17 00:00:00 2001 From: Michal Idziorek Date: Mon, 24 Nov 2014 11:07:32 +0100 Subject: implemented basic 'cd' in foolshell --- fs/ext2.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'fs/ext2.c') diff --git a/fs/ext2.c b/fs/ext2.c index 4db858f..82755de 100644 --- a/fs/ext2.c +++ b/fs/ext2.c @@ -281,6 +281,8 @@ int ext2_filename_to_inode_traverse(uint8_t *ram, char *path,int inode_start) } int ext2_filename_to_inode(uint8_t *ram, char *path) { + + if(true==strcmp(path,"/",0))return 2; // root is inode 2 by definition char buf[256]; for(int i=0;i<256;i++) { -- cgit v1.2.3