From a341238b1ebe807eb1b02ee1a2cd8e8192e9cf27 Mon Sep 17 00:00:00 2001 From: Kenneth R Westerback Date: Tue, 19 Jan 2016 23:33:19 +0000 Subject: It's pointless to check for 'dflag' inside do_expert(), since you can't get there unless dflag is set. Makes switch() statement easier to grasp. --- sbin/pdisk/pdisk.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'sbin/pdisk') diff --git a/sbin/pdisk/pdisk.c b/sbin/pdisk/pdisk.c index 7cfa20c7dfb..99300abf092 100644 --- a/sbin/pdisk/pdisk.c +++ b/sbin/pdisk/pdisk.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pdisk.c,v 1.52 2016/01/19 16:53:04 krw Exp $ */ +/* $OpenBSD: pdisk.c,v 1.53 2016/01/19 23:33:18 krw Exp $ */ /* * pdisk - an editor for Apple format partition tables @@ -542,10 +542,7 @@ do_expert(struct partition_map_header * map, char *name) printf("Commands are:\n"); printf(" h print help\n"); printf(" p print the partition table\n"); - if (dflag) { - printf(" P (show data structures - " - "debugging)\n"); - } + printf(" P (show data structures - debugging)\n"); printf(" f full display of nth entry\n"); printf(" v validate map\n"); printf(" q return to main edit menu\n"); @@ -566,11 +563,8 @@ do_expert(struct partition_map_header * map, char *name) goto finis; break; case 'P': - if (dflag) { - show_data_structures(map); - break; - } - /* fall through */ + show_data_structures(map); + break; case 'p': dump_partition_map(map, 1); break; -- cgit v1.2.3