1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-01-18 20:11:20 +00:00

BaseLinuxDevice: list_file_systems() now handles blank lines

mount() may return an empty line at the end of the output; this update
handles that.
This commit is contained in:
Sergei Trofimov 2015-11-24 15:48:28 +00:00
parent d9f1190e1f
commit c02a1118d7

View File

@ -301,6 +301,9 @@ class BaseLinuxDevice(Device): # pylint: disable=abstract-method
output = self.execute('mount')
fstab = []
for line in output.split('\n'):
line = line.strip()
if not line:
continue
match = FSTAB_ENTRY_REGEX.search(line)
if match:
fstab.append(FstabEntry(match.group(1), match.group(2),