aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/ufs/ffs/ffs_vfsops.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c
index f9fb854c9640..131bdc33f427 100644
--- a/sys/ufs/ffs/ffs_vfsops.c
+++ b/sys/ufs/ffs/ffs_vfsops.c
@@ -1015,9 +1015,10 @@ ffs_mountfs(odevvp, mp, td)
mp->mnt_flag |= MNT_GJOURNAL;
MNT_IUNLOCK(mp);
} else {
- printf("WARNING: %s: GJOURNAL flag on fs "
- "but no gjournal provider below\n",
- mp->mnt_stat.f_mntonname);
+ if ((mp->mnt_flag & MNT_RDONLY) == 0)
+ printf("WARNING: %s: GJOURNAL flag on fs "
+ "but no gjournal provider below\n",
+ mp->mnt_stat.f_mntonname);
free(mp->mnt_gjprovider, M_UFSMNT);
mp->mnt_gjprovider = NULL;
}