[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [OSSTEST PATCH 22/26] TestSupport: guest_prepare_disk: cope with no disk

If the guest has no runvars specifying any kind of disk, do not
attempt to mess about with unmounting it etc.

Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
 Osstest/TestSupport.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Osstest/TestSupport.pm b/Osstest/TestSupport.pm
index a6ab18f..7eb7bc4 100644
--- a/Osstest/TestSupport.pm
+++ b/Osstest/TestSupport.pm
@@ -1580,7 +1580,7 @@ sub guest_prepare_disk ($) {
     guest_umount_lv($gho->{Host}, $gho);
-    return if $gho->{Diskfmt} eq "none";
+    return if ($gho->{Diskfmt} // 'none') eq "none";
     target_cmd_root($gho->{Host}, <<END);
 mkdir -p $gho->{Diskmnt}

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.