From 7670572578b4d1e86167e6818f857a2cc855e589 Mon Sep 17 00:00:00 2001 From: Antti Rasinen Date: Tue, 16 Jul 2013 13:49:19 +0300 Subject: [PATCH] Fix zfs property parsing Current property parser breaks when values contain spaces. Since zfs get -H returns tab separated lines, it is better to explicitly split on tabs than on whitespace. --- library/system/zfs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/system/zfs b/library/system/zfs index 2428320313..162ac79741 100644 --- a/library/system/zfs +++ b/library/system/zfs @@ -316,9 +316,9 @@ class Zfs(object): cmd.append('get -H all') cmd.append(self.name) rc, out, err = self.module.run_command(' '.join(cmd)) - properties=dict() + properties = dict() for l in out.splitlines(): - p, v = l.split()[1:3] + p, v = l.split('\t')[1:3] properties[p] = v return properties