]> sourceware.org Git - lvm2.git/commitdiff
pvresize: add missing return
authorZdenek Kabelac <zkabelac@redhat.com>
Tue, 5 Jun 2018 19:21:26 +0000 (21:21 +0200)
committerZdenek Kabelac <zkabelac@redhat.com>
Fri, 8 Jun 2018 12:36:56 +0000 (14:36 +0200)
Log error path missed return 0.
Also fix some unneded bactraces (since log_error already shows
position).

WHATS_NEW
lib/metadata/pv_manip.c

index a727a40d289439af613c4e7c02c4badb39d3af82..a17902d1729f4b6a805c67be6c66959d72e7b1d9 100644 (file)
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
 Version 3.0.0
 =============
+  Fix check if resized PV can also fit metadata area.
   Avoid showing internal error in lvs output or pvmoved LVs.
   Remove clvmd
   Remove lvmlib (api)
index eaaa5e6e84acbb37f69f8cd69c32da1878e8774f..5fd80a2ceca36e0a14b306b4eac442f4f3d15aa1 100644 (file)
@@ -566,6 +566,7 @@ static int _pv_resize(struct physical_volume *pv, struct volume_group *vg, uint6
                log_error("Size must exceed physical extent start "
                          "of %" PRIu64 " sectors on PV %s.",
                          pv_pe_start(pv), pv_dev_name(pv));
+               return 0;
        }
 
        old_pe_count = pv->pe_count;
@@ -645,7 +646,7 @@ int pv_resize_single(struct cmd_context *cmd,
                                                  pv_name, display_size(cmd, new_size),
                                                  display_size(cmd, size)) == 'n') {
                                log_error("Physical Volume %s not resized.", pv_name);
-                               goto_out;
+                               goto out;
                        }
 
                }  else if (new_size < size)
@@ -653,7 +654,7 @@ int pv_resize_single(struct cmd_context *cmd,
                                                  pv_name, display_size(cmd, new_size),
                                                  display_size(cmd, size)) == 'n') {
                                log_error("Physical Volume %s not resized.", pv_name);
-                               goto_out;
+                               goto out;
                        }
 
                if (new_size == size)
This page took 0.051792 seconds and 5 git commands to generate.