summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1996-01-01 21:38:04 +0000
committerMichael I. Bushnell <mib@gnu.org>1996-01-01 21:38:04 +0000
commita3127e234a63121775f2113df40d49e31ac3b5ff (patch)
tree85ea277c5a28d4e9a66e3524395e7a549fc4d66f
parent39cb433c642277377ffec8f5aa17e63c5f94d849 (diff)
(pager_unlock_page): When allocating block in direct array, clear it
synchronously just like we do when it goes in the indirect array.
-rw-r--r--ufs/pager.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ufs/pager.c b/ufs/pager.c
index 87217908..26f5f322 100644
--- a/ufs/pager.c
+++ b/ufs/pager.c
@@ -1,5 +1,5 @@
/* Pager for ufs
- Copyright (C) 1994, 1995 Free Software Foundation
+ Copyright (C) 1994, 1995, 1996 Free Software Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -244,6 +244,8 @@ pager_unlock_page (struct user_pager_info *pager,
if (err)
goto out;
assert (lblkno (sblock, address) < NDADDR);
+ diskfs_device_write_sync (fsbtodb (sblock, bno),
+ zeroblock, sblock->fs_bsize);
indirs[0].bno = di->di_db[lblkno (sblock, address)] = bno;
record_poke (di, sizeof (struct dinode));
}