summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 79d8340)
raw | patch | inline | side by side (parent: 79d8340)
author | Jan Kundrát <jan.kundrat@cesnet.cz> | |
Thu, 20 Feb 2014 01:13:20 +0000 (02:13 +0100) | ||
committer | Marc Fournier <marc.fournier@camptocamp.com> | |
Fri, 8 Aug 2014 07:29:01 +0000 (09:29 +0200) |
src/lvm.c | patch | blob | history |
diff --git a/src/lvm.c b/src/lvm.c
index cb073321240e8ed8c379e8abefe704957bc249d3..bd2274014d2f7db1451e5d5790dd50be6b5118c5 100644 (file)
--- a/src/lvm.c
+++ b/src/lvm.c
lvm_submit (vg_name, "free", lvm_vg_get_free_size(vg));
lvs = lvm_vg_list_lvs(vg);
+ if (!lvs) {
+ /* no VGs are defined, which is not an error per se */
+ return (0);
+ }
+
dm_list_iterate_items(lvl, lvs) {
name = lvm_lv_get_name(lvl->lv);
attrs = get_lv_property_string(lvl->lv, "lv_attr");