]> Devi Nivas Git - cs3210-lab1.git/commitdiff
Explain why itrunc() is OK w.r.t. crashes.
authorrtm <rtm>
Mon, 20 Oct 2008 18:05:48 +0000 (18:05 +0000)
committerrtm <rtm>
Mon, 20 Oct 2008 18:05:48 +0000 (18:05 +0000)
fs.c

diff --git a/fs.c b/fs.c
index 70c7ec1983a42465d03bda32034c3c1f6a08aaf2..91533d1d92a0dd1fb498e2fe64633bc79c9cce38 100644 (file)
--- a/fs.c
+++ b/fs.c
@@ -359,6 +359,8 @@ bmap(struct inode *ip, uint bn, int alloc)
 }
 
 // Truncate inode (discard contents).
+// Only called after the last dirent referring
+// to this inode has been erased on disk.
 static void
 itrunc(struct inode *ip)
 {