From 6bf230cf4d9b75d564193af61b43502ed548e483 Mon Sep 17 00:00:00 2001 From: Pawel Marczewski Date: Thu, 9 Jan 2020 12:37:43 +0100 Subject: [PATCH] Don't try to write to qubesdb of an offline VM --- qubes/vm/mix/net.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/qubes/vm/mix/net.py b/qubes/vm/mix/net.py index 5b31014c..d53bbae4 100644 --- a/qubes/vm/mix/net.py +++ b/qubes/vm/mix/net.py @@ -446,13 +446,14 @@ class NetVMMixin(qubes.events.Emitter): ''' # pylint: disable=unused-argument - if oldvalue is not None: + if oldvalue is not None and oldvalue.is_running(): oldvalue.reload_connected_ips() if newvalue is None: return - newvalue.reload_connected_ips() + if newvalue.is_running(): + newvalue.reload_connected_ips() if self.is_running(): # refresh IP, DNS etc