Module Name: src
Committed By: reinoud
Date: Fri Jan 21 22:32:13 UTC 2011
Modified Files:
src/sbin/newfs_udf: newfs_udf.c
Log Message:
When requesting to disable metadata partitions, also disable low formatting.
When no meta and not low formatting we can lower the required UDF version.
To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sbin/newfs_udf/newfs_udf.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sbin/newfs_udf/newfs_udf.c
diff -u src/sbin/newfs_udf/newfs_udf.c:1.10 src/sbin/newfs_udf/newfs_udf.c:1.11
--- src/sbin/newfs_udf/newfs_udf.c:1.10 Fri Jan 21 22:10:51 2011
+++ src/sbin/newfs_udf/newfs_udf.c Fri Jan 21 22:32:13 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: newfs_udf.c,v 1.10 2011/01/21 22:10:51 reinoud Exp $ */
+/* $NetBSD: newfs_udf.c,v 1.11 2011/01/21 22:32:13 reinoud Exp $ */
/*
* Copyright (c) 2006, 2008 Reinoud Zandijk
@@ -573,7 +573,7 @@
/* enable/disable requests */
if (req_disable & FORMAT_META) {
- format_flags &= ~FORMAT_META;
+ format_flags &= ~(FORMAT_META | FORMAT_LOW);
req_disable &= ~FORMAT_META;
}
if (req_disable || req_enable) {
@@ -608,7 +608,8 @@
context.min_udf = MAX(context.min_udf, 0x0260);
/* adjust maximum version limits not to tease or break things */
- if (!(format_flags & FORMAT_META) && (context.max_udf > 0x200))
+ if (!(format_flags & (FORMAT_META | FORMAT_LOW)) &&
+ (context.max_udf > 0x200))
context.max_udf = 0x201;
if ((format_flags & (FORMAT_VAT | FORMAT_SPARABLE)) == 0)