summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1999-10-28 06:27:10 +0000
committerRoland McGrath <roland@gnu.org>1999-10-28 06:27:10 +0000
commit75e1175006e01e50bdb7243e031c3d0eb987cc08 (patch)
treec0e7dd2febe5fba749bc659acb694c0e43cdd70e
parent9b16f7958a9a5117c88da42ace1dba28b66dec71 (diff)
1999-10-28 Roland McGrath <roland@baalperazim.frob.com>
* node-nput.c (diskfs_nput): Call diskfs_set_node_times before diskfs_lost_hardrefs. This should address the late mtime update bug reported and investigated by Mark Kettenis.
-rw-r--r--libdiskfs/node-nput.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libdiskfs/node-nput.c b/libdiskfs/node-nput.c
index 425b2216..2f4a7db4 100644
--- a/libdiskfs/node-nput.c
+++ b/libdiskfs/node-nput.c
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 1999 Free Software Foundation, Inc.
Written by Thomas Bushnell, BSG.
@@ -37,6 +37,12 @@ diskfs_nput (struct node *np)
else if (np->references == 0 && !tried_drop_softrefs)
{
spin_unlock (&diskfs_node_refcnt_lock);
+
+ /* This is our cue that something akin to "last process closes file"
+ in the POSIX.1 sense happened, so make sure any pending node time
+ updates now happen in a timely fashion. */
+ diskfs_set_node_times (np);
+
diskfs_lost_hardrefs (np);
if (!np->dn_stat.st_nlink)
{