summaryrefslogtreecommitdiff
path: root/Source/Kernel/VFS/VFS.ns.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Kernel/VFS/VFS.ns.cpp')
-rw-r--r--Source/Kernel/VFS/VFS.ns.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/Source/Kernel/VFS/VFS.ns.cpp b/Source/Kernel/VFS/VFS.ns.cpp
index 30ad2d7..2333a36 100644
--- a/Source/Kernel/VFS/VFS.ns.cpp
+++ b/Source/Kernel/VFS/VFS.ns.cpp
@@ -103,9 +103,7 @@ FSNode* createDirectory(const String& path, FSNode* start) {
}
}
-bool remove(const String& path, FSNode* start) {
- FSNode* node = find(path, start);
- if (node == NULL) return false;
+bool remove(FSNode* node) {
FSNode* parent = node->getParent();
if (parent == NULL) return false;
@@ -116,6 +114,12 @@ bool remove(const String& path, FSNode* start) {
}
}
+bool remove(const String& path, FSNode* start) {
+ FSNode* node = find(path, start);
+ if (node == NULL) return false;
+ return remove(node);
+}
+
String path(FSNode* node) {
String path;