blob: be997ac4f4f6998855f5ce5ef47bafc0e4ebca1b [file] [log] [blame]
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08001From c31df1c0f5323ddc70e0d1c6d11db2fbf7a024ad Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Mon, 8 May 2017 16:30:20 +0800
4Subject: [PATCH 04/11] fix new.roots object is not iterable
5
6Upstream-Status: Pending
7
8Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
9---
10 blivet/blivet.py | 2 +-
11 1 file changed, 1 insertion(+), 1 deletion(-)
12
13diff --git a/blivet/blivet.py b/blivet/blivet.py
14index 3405810..f42b73b 100644
15--- a/blivet/blivet.py
16+++ b/blivet/blivet.py
17@@ -1198,7 +1198,7 @@ class Blivet(object):
18 p = partition.disk.format.parted_disk.getPartitionByPath(partition.path)
19 partition.parted_partition = p
20
21- for root in new.roots:
22+ for root in new.roots or []:
23 root.swaps = [new.devicetree.get_device_by_id(d.id, hidden=True) for d in root.swaps]
24 root.swaps = [s for s in root.swaps if s]
25
26--
272.7.4
28