From c5810758c50375cb80775568386672f7b4b94b33 Mon Sep 17 00:00:00 2001 From: Bahtiar `kalkin-` Gadimov Date: Thu, 5 May 2016 18:48:34 +0200 Subject: [PATCH] FilePool fix origin volume removale --- qubes/storage/file.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qubes/storage/file.py b/qubes/storage/file.py index a405e475..14794164 100644 --- a/qubes/storage/file.py +++ b/qubes/storage/file.py @@ -112,7 +112,6 @@ class FilePool(Pool): _remove_if_exists(volume) elif volume.volume_type == 'origin': _remove_if_exists(volume) - _remove_if_exists(volume) def rename(self, volume, old_name, new_name): assert issubclass(volume.__class__, FileVolume) @@ -493,6 +492,8 @@ def copy_file(source, destination): def _remove_if_exists(volume): if os.path.exists(volume.path): os.remove(volume.path) + if volume.volume_type == 'origin': + os.remove(volume.path_cow) def _check_path(path):