diff options
-rw-r--r-- | ext2fs/dir.c | 6 | ||||
-rw-r--r-- | ext2fs/truncate.c | 5 | ||||
-rw-r--r-- | libdiskfs/dir-init.c | 2 | ||||
-rw-r--r-- | libdiskfs/dir-link.c | 2 | ||||
-rw-r--r-- | libdiskfs/dir-rename.c | 2 | ||||
-rw-r--r-- | libdiskfs/dir-renamed.c | 2 | ||||
-rw-r--r-- | libdiskfs/file-set-trans.c | 2 | ||||
-rw-r--r-- | libdiskfs/node-create.c | 2 | ||||
-rw-r--r-- | libdiskfs/node-drop.c | 2 |
9 files changed, 13 insertions, 12 deletions
diff --git a/ext2fs/dir.c b/ext2fs/dir.c index d70dbf32..714c1b7c 100644 --- a/ext2fs/dir.c +++ b/ext2fs/dir.c @@ -690,7 +690,7 @@ diskfs_direnter_hard (struct node *dp, const char *name, struct node *np, } } - diskfs_file_update (dp, 1); + diskfs_file_update (dp, diskfs_synchronous); return 0; } @@ -727,7 +727,7 @@ diskfs_dirremove_hard (struct node *dp, struct dirstat *ds) if (dp->dn->dirents && dp->dn->dirents[ds->idx] != -1) dp->dn->dirents[ds->idx]--; - diskfs_file_update (dp, 1); + diskfs_file_update (dp, diskfs_synchronous); return 0; } @@ -753,7 +753,7 @@ diskfs_dirrewrite_hard (struct node *dp, struct node *np, struct dirstat *ds) munmap ((caddr_t) ds->mapbuf, ds->mapextent); - diskfs_file_update (dp, 1); + diskfs_file_update (dp, diskfs_synchronous); return 0; } diff --git a/ext2fs/truncate.c b/ext2fs/truncate.c index 077225b0..2058a1c1 100644 --- a/ext2fs/truncate.c +++ b/ext2fs/truncate.c @@ -294,7 +294,7 @@ diskfs_truncate (struct node *node, off_t length) node->dn_stat.st_size = length; node->dn_set_mtime = 1; node->dn_set_ctime = 1; - diskfs_node_update (node, 1); + diskfs_node_update (node, diskfs_synchronous); return 0; } @@ -309,6 +309,7 @@ diskfs_truncate (struct node *node, off_t length) { diskfs_node_rdwr (node, (void *)zeroblock, length, block_size - offset, 1, 0, 0); + /* Make sure that really happens to avoid leaks. */ diskfs_file_update (node, 1); } @@ -323,7 +324,7 @@ diskfs_truncate (struct node *node, off_t length) node->dn_stat.st_size = length; node->dn_set_mtime = 1; node->dn_set_ctime = 1; - diskfs_node_update (node, 1); + diskfs_node_update (node, diskfs_synchronous); err = diskfs_catch_exception (); if (!err) diff --git a/libdiskfs/dir-init.c b/libdiskfs/dir-init.c index 2cba3a4b..4efded07 100644 --- a/libdiskfs/dir-init.c +++ b/libdiskfs/dir-init.c @@ -63,6 +63,6 @@ diskfs_init_dir (struct node *dp, struct node *pdp, struct protid *cred) return err; } - diskfs_node_update (dp, 1); + diskfs_node_update (dp, diskfs_synchronous); return 0; } diff --git a/libdiskfs/dir-link.c b/libdiskfs/dir-link.c index 81a45b5f..82f8aeec 100644 --- a/libdiskfs/dir-link.c +++ b/libdiskfs/dir-link.c @@ -101,7 +101,7 @@ diskfs_S_dir_link (struct protid *dircred, } np->dn_stat.st_nlink++; np->dn_set_ctime = 1; - diskfs_node_update (np, 1); + diskfs_node_update (np, diskfs_synchronous); /* Attach it */ if (tnp) diff --git a/libdiskfs/dir-rename.c b/libdiskfs/dir-rename.c index 867e395d..298669be 100644 --- a/libdiskfs/dir-rename.c +++ b/libdiskfs/dir-rename.c @@ -164,7 +164,7 @@ diskfs_S_dir_rename (struct protid *fromcred, } fnp->dn_stat.st_nlink++; fnp->dn_set_ctime = 1; - diskfs_node_update (fnp, 1); + diskfs_node_update (fnp, diskfs_synchronous); if (tnp) { diff --git a/libdiskfs/dir-renamed.c b/libdiskfs/dir-renamed.c index 79381b2c..3064dbaf 100644 --- a/libdiskfs/dir-renamed.c +++ b/libdiskfs/dir-renamed.c @@ -176,7 +176,7 @@ diskfs_rename_dir (struct node *fdp, struct node *fnp, const char *fromname, } fnp->dn_stat.st_nlink++; fnp->dn_set_ctime = 1; - diskfs_node_update (fnp, 1); + diskfs_node_update (fnp, diskfs_synchronous); if (tnp) { diff --git a/libdiskfs/file-set-trans.c b/libdiskfs/file-set-trans.c index 26a19eb4..c9b2c613 100644 --- a/libdiskfs/file-set-trans.c +++ b/libdiskfs/file-set-trans.c @@ -196,7 +196,7 @@ diskfs_S_file_set_translator (struct protid *cred, if (!error) { np->dn_stat.st_mode = newmode; - diskfs_node_update (np, 1); + diskfs_node_update (np, diskfs_synchronous); } mutex_unlock (&np->lock); return error; diff --git a/libdiskfs/node-create.c b/libdiskfs/node-create.c index 4a7d108d..5b5e4639 100644 --- a/libdiskfs/node-create.c +++ b/libdiskfs/node-create.c @@ -131,7 +131,7 @@ diskfs_create_node (struct node *dir, if (S_ISDIR (mode)) err = diskfs_init_dir (np, dir, cred); - diskfs_node_update (np, 1); + diskfs_node_update (np, diskfs_synchronous); if (err) { diff --git a/libdiskfs/node-drop.c b/libdiskfs/node-drop.c index f44966ba..c3d32c96 100644 --- a/libdiskfs/node-drop.c +++ b/libdiskfs/node-drop.c @@ -78,7 +78,7 @@ diskfs_drop_node (struct node *np) np->dn_stat.st_mode = 0; np->dn_stat.st_rdev = 0; np->dn_set_ctime = np->dn_set_atime = 1; - diskfs_node_update (np, 1); + diskfs_node_update (np, diskfs_synchronous); diskfs_free_node (np, savemode); } else |