summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2017-12-06 13:21:01 +0100
committerZdenek Kabelac <zkabelac@redhat.com>2017-12-07 20:59:37 +0100
commitc3e224ad0ebd473268b171204c8985c9c642f590 (patch)
tree0f7284cbc1f76d028ca1d480b29fa50fe10096b5
parent2208ebfe16e5b5cd54c762a5a06edd0681d62fa9 (diff)
downloadlvm2-c3e224ad0ebd473268b171204c8985c9c642f590.tar.gz
thin: missing type is error
-rw-r--r--libdm/libdm-deptree.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libdm/libdm-deptree.c b/libdm/libdm-deptree.c
index b844a5735..1ef1700fe 100644
--- a/libdm/libdm-deptree.c
+++ b/libdm/libdm-deptree.c
@@ -1394,9 +1394,9 @@ static int _thin_pool_get_status(struct dm_tree_node *dnode,
dm_get_next_target(dmt, NULL, &start, &length, &type, &params);
- if (type && (strcmp(type, "thin-pool") != 0)) {
+ if (!type || (strcmp(type, "thin-pool") != 0)) {
log_error("Expected thin-pool target for %s and got %s.",
- _node_name(dnode), type);
+ _node_name(dnode), type ? : "no target");
goto out;
}