summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Bluhm <bluhm@cvs.openbsd.org>2013-10-15 20:13:03 +0000
committerAlexander Bluhm <bluhm@cvs.openbsd.org>2013-10-15 20:13:03 +0000
commit5397f8b6910445c2fced2fd9b1b747c7a39c336f (patch)
tree9bb05688e9e7f198adebc27d89b3d4948eaf9e33
parentdf04dad9f79e99a79915b5f2ca26d7339bcd82b0 (diff)
The disklabel variables aflag and dflag are boolean, use logical
instead of binary operators for comparison. OK krw@
-rw-r--r--sbin/disklabel/disklabel.c4
-rw-r--r--sbin/disklabel/editor.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sbin/disklabel/disklabel.c b/sbin/disklabel/disklabel.c
index 2facc7128c3..6a797cdb7ae 100644
--- a/sbin/disklabel/disklabel.c
+++ b/sbin/disklabel/disklabel.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disklabel.c,v 1.189 2013/10/03 18:50:30 krw Exp $ */
+/* $OpenBSD: disklabel.c,v 1.190 2013/10/15 20:13:02 bluhm Exp $ */
/*
* Copyright (c) 1987, 1993
@@ -261,7 +261,7 @@ main(int argc, char *argv[])
fclose(t);
break;
case WRITE:
- if (dflag | aflag) {
+ if (dflag || aflag) {
readlabel(f);
} else if (argc < 2 || argc > 3)
usage();
diff --git a/sbin/disklabel/editor.c b/sbin/disklabel/editor.c
index 393516ee9ee..665ca82d30b 100644
--- a/sbin/disklabel/editor.c
+++ b/sbin/disklabel/editor.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: editor.c,v 1.273 2013/10/03 18:50:30 krw Exp $ */
+/* $OpenBSD: editor.c,v 1.274 2013/10/15 20:13:02 bluhm Exp $ */
/*
* Copyright (c) 1997-2000 Todd C. Miller <Todd.Miller@courtesan.com>
@@ -206,7 +206,7 @@ editor(int f)
}
#ifdef SUN_CYLCHECK
- if ((newlab.d_flags & D_VENDOR) & !aflag) {
+ if ((newlab.d_flags & D_VENDOR) && !aflag) {
puts("This platform requires that partition offsets/sizes "
"be on cylinder boundaries.\n"
"Partition offsets/sizes will be rounded to the "