From 95d7001a708f2956ae6598d3cb3ad3ac74227a02 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Sun, 28 Jul 1996 01:44:01 +0000 Subject: (diskfs_S_fsys_syncfs): Don't sync if DISKFS_READONLY. --- libdiskfs/fsys-syncfs.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'libdiskfs') diff --git a/libdiskfs/fsys-syncfs.c b/libdiskfs/fsys-syncfs.c index 81477113..503eea4c 100644 --- a/libdiskfs/fsys-syncfs.c +++ b/libdiskfs/fsys-syncfs.c @@ -1,5 +1,5 @@ /* - Copyright (C) 1994, 1995 Free Software Foundation, Inc. + Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc. Written by Michael I. Bushnell. This file is part of the GNU Hurd. @@ -60,8 +60,11 @@ diskfs_S_fsys_syncfs (fsys_t controlport, if (diskfs_synchronous) wait = 1; - diskfs_sync_everything (wait); - diskfs_set_hypermetadata (wait, 0); + if (! diskfs_readonly) + { + diskfs_sync_everything (wait); + diskfs_set_hypermetadata (wait, 0); + } rwlock_reader_unlock (&diskfs_fsys_lock); -- cgit v1.2.3