summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitya Selivanov <automainint@guattari.tech>2023-09-15 23:12:36 +0200
committerMitya Selivanov <automainint@guattari.tech>2023-09-15 23:12:36 +0200
commitc54a81fd03631bbf2241cd70455ec016011ad762 (patch)
tree47d995a7f53bd5764af162b28d18761c60ffa00e
parent713907ef2f1f481641530123ff60404d5a1e755f (diff)
downloadkit-c54a81fd03631bbf2241cd70455ec016011ad762.zip
test
-rw-r--r--source/kit/file.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/kit/file.c b/source/kit/file.c
index 7f971af..674ea94 100644
--- a/source/kit/file.c
+++ b/source/kit/file.c
@@ -429,6 +429,10 @@ kit_path_list_t kit_folder_enum(kit_str_t path,
return result;
do {
+ if (strcmp(data.cFileName, ".") == 0 ||
+ strcmp(data.cFileName, "..") == 0)
+ continue;
+
i64 n = result.files.size;
DA_RESIZE(result.files, n + 1);
if (result.files.size != n + 1) {