[PATCH] partx: do not print null

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Davidlohr Bueso <dave@xxxxxxx>
Date: Fri, 12 Aug 2011 15:36:50 -0400

Replace the annoying null output when displaying no partitions in verbose mode.

Signed-off-by: Davidlohr Bueso <dave@xxxxxxx>
---
 partx/partx.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/partx/partx.c b/partx/partx.c
index b2a72ed..0b35f9f 100644
--- a/partx/partx.c
+++ b/partx/partx.c
@@ -795,7 +795,7 @@ int main(int argc, char **argv)
 
 	if (verbose)
 		printf(_("partition: %s, disk: %s, lower: %d, upper: %d\n"),
-				device, wholedisk, lower, upper);
+		       device ? device : "none", wholedisk, lower, upper);
 
 	if (what == ACT_ADD || what == ACT_DELETE) {
 		struct stat x;
-- 
1.7.4.1



--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux