fs: prevalidation for root folder, code despaghettizing

git-svn-id: svn://kolibrios.org@6845 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
pathoswithin
2017-01-22 16:19:39 +00:00
parent e828b2c8b5
commit 201a5bf041
5 changed files with 193 additions and 347 deletions

View File

@@ -1753,9 +1753,6 @@ writeSuperblock:
ret
extfsWritingInit:
movi eax, ERROR_ACCESS_DENIED
cmp byte [esi], 0
jz @f
movi eax, ERROR_UNSUPPORTED_FS
test [ebp+EXTFS.mountType], READ_ONLY
jnz @f
@@ -1987,10 +1984,7 @@ ext_ReadFolder:
;----------------------------------------------------------------
ext_ReadFile:
call ext_lock
pushd 0 ERROR_ACCESS_DENIED
cmp byte [esi], 0
jz .ret ; root
mov [esp], ebx
pushd 0 ebx
call findInode
pop ebx
push eax