From a14e270ff21501fee66bd9f7d85a778ffa4b6c2c Mon Sep 17 00:00:00 2001 From: Yuxin Wu Date: Mon, 29 Jun 2020 03:30:15 -0700 Subject: [PATCH] remove failed decryption --- decrypt-db.py | 1 + 1 file changed, 1 insertion(+) diff --git a/decrypt-db.py b/decrypt-db.py index 07bf40c..8d763f8 100755 --- a/decrypt-db.py +++ b/decrypt-db.py @@ -124,6 +124,7 @@ def do_decrypt(input, output, key): c.execute("ATTACH DATABASE '" + output + "' AS db KEY '';") except Exception as e: logger.error(f"Decryption failed: '{e}'") + os.unlink(output) raise logger.info(f"Decryption succeeded! Writing database to {output} ...") c.execute("SELECT sqlcipher_export('db');" )