From 2e2b6bb1c7f5ed37a8d7186bfdd21b5976a46823 Mon Sep 17 00:00:00 2001 From: Davidlohr Bueso Date: Fri, 12 Aug 2011 15:36:50 -0400 Subject: [PATCH] partx: do not print null Replace the annoying null output when displaying no partitions in verbose mode. Signed-off-by: Davidlohr Bueso --- partx/partx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/partx/partx.c b/partx/partx.c index b2a72ede3b..0b35f9f482 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; -- 2.47.3