summaryrefslogtreecommitdiff
path: root/Source/Kernel/FileSystems/RamFS/RamFileNode.class.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Kernel/FileSystems/RamFS/RamFileNode.class.h')
-rw-r--r--Source/Kernel/FileSystems/RamFS/RamFileNode.class.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/Kernel/FileSystems/RamFS/RamFileNode.class.h b/Source/Kernel/FileSystems/RamFS/RamFileNode.class.h
index d600630..2abad64 100644
--- a/Source/Kernel/FileSystems/RamFS/RamFileNode.class.h
+++ b/Source/Kernel/FileSystems/RamFS/RamFileNode.class.h
@@ -11,6 +11,8 @@ class RamFileNode : public FileNode {
u32int uid = 0, u32int gid = 0) :
FileNode(name, fs, parent, 0, permissions, uid, gid), m_data(0) {}
+ ~RamFileNode() { if (m_data != 0) delete m_data; }
+
u8int *m_data; //We don't take care of allocation/freeing here, RamFS:: does that for us
void setLength(u32int length) { m_length = length; }