Kernel: Allow listing files even if one of directories blocks are empty
This commit is contained in:
@@ -331,6 +331,9 @@ done:
|
||||
return BAN::Error::from_errno(ENOBUFS);
|
||||
}
|
||||
|
||||
if (entry_count == 0)
|
||||
return BAN::Error::from_errno(ENODATA);
|
||||
|
||||
// Second fill the list
|
||||
{
|
||||
dirent* dirp = list;
|
||||
|
||||
@@ -475,6 +475,8 @@ namespace Kernel
|
||||
}
|
||||
});
|
||||
|
||||
if (entry_count == 0)
|
||||
return BAN::Error::from_errno(ENODATA);
|
||||
return entry_count;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user