[PATCH] tmpfs 2/4 mknod times

Hugh Dickins (hugh@veritas.com)
Wed, 12 Jun 2002 03:54:03 +0100 (BST)


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/