mirror of
https://github.com/RGBCube/serenity
synced 2025-07-08 23:07:35 +00:00
FileManager: Don't show "." and ".." in directory views.
This commit is contained in:
parent
f18ed4f633
commit
900a3966e2
2 changed files with 3 additions and 1 deletions
|
@ -227,6 +227,8 @@ void DirectoryModel::update()
|
|||
while (auto* de = readdir(dirp)) {
|
||||
Entry entry;
|
||||
entry.name = de->d_name;
|
||||
if (entry.name == "." || entry.name == "..")
|
||||
continue;
|
||||
struct stat st;
|
||||
int rc = lstat(String::format("%s/%s", m_path.characters(), de->d_name).characters(), &st);
|
||||
if (rc < 0) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue