[PATCH] tmpfs 2/4 mknod times

From: Hugh Dickins (hugh@veritas.com)
Date: Tue Jun 11 2002 - 21:54:03 EST


shmem_mknod should not update directory times if it cannot get an inode.

--- 2.4.19-pre10/mm/shmem.c Tue Jun 11 19:02:30 2002
+++ linux/mm/shmem.c Tue Jun 11 19:02:30 2002
@@ -987,8 +987,8 @@
         struct inode * inode = shmem_get_inode(dir->i_sb, mode, dev);
         int error = -ENOSPC;
 
- dir->i_ctime = dir->i_mtime = CURRENT_TIME;
         if (inode) {
+ dir->i_ctime = dir->i_mtime = CURRENT_TIME;
                 d_instantiate(dentry, inode);
                 dget(dentry); /* Extra count - pin the dentry in core */
                 error = 0;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Jun 15 2002 - 22:00:24 EST