M #-: escape special chars in vCenter disk names (#387)

This commit is contained in:
Alejandro Huertas Herrero authored and GitHub committed 2020-11-03 16:19:00 +01:00
1 parent bc4a726fac
commit 06a37707fe
1 file changed
+1 -3
@@ -465,10 +465,8 @@ module VirtualMachineMonitor
info_disks.each do |disk|
next if disk[1].no_exists?
name = disk[0]
# Delete special characters
name.gsub!(/[^0-9A-Za-z]/, '_')
name = disk[0].gsub(/[^0-9A-Za-z]/, '_')
str_info << "DISK_#{name}_ACTUAL_PATH=\"[" <<
disk[1].ds.name << '] ' << disk[1].path << '" ' << "\n"