diff options
author | Karel Zak | 2013-09-17 09:42:53 +0200 |
---|---|---|
committer | Karel Zak | 2013-09-17 09:42:53 +0200 |
commit | ffcf0540412eb532be3a446c9f6f1dc1bd16e20c (patch) | |
tree | 2baf386c3ff1442bab2eab247f5174dd84f46085 /fdisks | |
parent | fdisk: fix -l (diff) | |
download | kernel-qcow2-util-linux-ffcf0540412eb532be3a446c9f6f1dc1bd16e20c.tar.gz kernel-qcow2-util-linux-ffcf0540412eb532be3a446c9f6f1dc1bd16e20c.tar.xz kernel-qcow2-util-linux-ffcf0540412eb532be3a446c9f6f1dc1bd16e20c.zip |
fdisk: add debug message, use colors for -l
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'fdisks')
-rw-r--r-- | fdisks/fdisk.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fdisks/fdisk.c b/fdisks/fdisk.c index 368c89ed0..9b7487613 100644 --- a/fdisks/fdisk.c +++ b/fdisks/fdisk.c @@ -487,9 +487,12 @@ int main(int argc, char **argv) warnx(_("The device properties (sector size and geometry) should" " be used with one specified device only.")); + colors_init(colormode); + switch (act) { case ACT_LIST: fdisk_context_enable_listonly(cxt, 1); + if (argc > optind) { int k; for (k = optind; k < argc; k++) @@ -515,8 +518,6 @@ int main(int argc, char **argv) if (argc-optind != 1) usage(stderr); - colors_init(colormode); - if (fdisk_context_assign_device(cxt, argv[optind], 0) != 0) err(EXIT_FAILURE, _("cannot open %s"), argv[optind]); |