From 78689645dcedbe0f7da89d1108193141f0e9eeb6 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 31 Jan 2014 22:24:28 +0100 Subject: [PATCH] db/update/Archive: delete archive from database on error --- src/db/update/Archive.cxx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/db/update/Archive.cxx b/src/db/update/Archive.cxx index 6d47ae0d1..0d7127685 100644 --- a/src/db/update/Archive.cxx +++ b/src/db/update/Archive.cxx @@ -123,6 +123,8 @@ UpdateWalk::UpdateArchiveFile(Directory &parent, const char *name, ArchiveFile *file = archive_file_open(&plugin, path_fs.c_str(), error); if (file == nullptr) { LogError(error); + if (directory != nullptr) + editor.LockDeleteDirectory(directory); return; }