diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2016-11-25 13:46:06 +0100 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2016-11-25 14:58:28 +0100 |
commit | 1d58074d9fc4a01c5ca99af0ba26a5521a541092 (patch) | |
tree | 35b0966442c289223aac7212fca5371bcc44b3d8 /tools/vgimportclone.c | |
parent | 2ad66b4e7bf1c88bd57b6d97f9feb07b99ae3e19 (diff) | |
download | lvm2-1d58074d9fc4a01c5ca99af0ba26a5521a541092.tar.gz |
debug: more stacktrace corrections
Continue previous patch dropping some unneeded stack traces
after printed log_error/warn messages.
Diffstat (limited to 'tools/vgimportclone.c')
-rw-r--r-- | tools/vgimportclone.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/tools/vgimportclone.c b/tools/vgimportclone.c index 09b3a7c3f..b23b14e87 100644 --- a/tools/vgimportclone.c +++ b/tools/vgimportclone.c @@ -75,12 +75,12 @@ static int _vgimportclone_vg_single(struct cmd_context *cmd, const char *vg_name if (vg_is_exported(vg) && !vp->import_vg) { log_error("VG %s is exported, use the --import option.", vg->name); - goto_bad; + goto bad; } if (vg_status(vg) & PARTIAL_VG) { log_error("VG %s is partial, it must be complete.", vg->name); - goto_bad; + goto bad; } /* @@ -121,7 +121,7 @@ static int _vgimportclone_vg_single(struct cmd_context *cmd, const char *vg_name log_error("PV with UUID %s is part of VG %s, but is not included in the devices to import.", uuid, vg->name); log_error("All PVs in the VG must be imported together."); - goto_bad; + goto bad; } } @@ -130,7 +130,7 @@ static int _vgimportclone_vg_single(struct cmd_context *cmd, const char *vg_name /* device arg is not in the VG. */ log_error("Device %s was not found in VG %s.", dev_name(vd->dev), vg->name); log_error("The devices to import must match the devices in the VG."); - goto_bad; + goto bad; } } @@ -245,7 +245,7 @@ int vgimportclone(struct cmd_context *cmd, int argc, char **argv) if (vp.found_args != argc) { log_error("Failed to find all devices."); - goto_out; + goto out; } /* @@ -256,12 +256,12 @@ int vgimportclone(struct cmd_context *cmd, int argc, char **argv) dm_list_iterate_items(vd, &vp.arg_import) { if (!(info = lvmcache_info_from_pvid(vd->dev->pvid, NULL, 0))) { log_error("Failed to find PVID for device %s in lvmcache.", dev_name(vd->dev)); - goto_out; + goto out; } if (!(vgname = lvmcache_vgname_from_info(info))) { log_error("Failed to find VG name for device %s in lvmcache.", dev_name(vd->dev)); - goto_out; + goto out; } if (!vp.old_vgname) { @@ -270,7 +270,7 @@ int vgimportclone(struct cmd_context *cmd, int argc, char **argv) } else { if (strcmp(vp.old_vgname, vgname)) { log_error("Devices must be from the same VG."); - goto_out; + goto out; } } } @@ -360,4 +360,3 @@ out: return ret; } - |