about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2014-11-12T10·35+0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2014-11-12T10·35+0100
commitbab8d9b52a75276980fed9288573abf4eb7308f8 (patch)
tree8389416fdb5bc4ff8c7488b075da030f6a555a5e /src
parentd436e44ae3a7fc310660db0cc3078a9c1c9318e4 (diff)
Make ~DerivationGoal more reliable
Diffstat (limited to 'src')
-rw-r--r--src/libstore/build.cc10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index e8067acbdd4d..5aea4742a97b 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -851,13 +851,9 @@ DerivationGoal::~DerivationGoal()
 {
     /* Careful: we should never ever throw an exception from a
        destructor. */
-    try {
-        killChild();
-        deleteTmpDir(false);
-        closeLogFile();
-    } catch (...) {
-        ignoreException();
-    }
+    try { killChild(); } catch (...) { ignoreException(); }
+    try { deleteTmpDir(false); } catch (...) { ignoreException(); }
+    try { closeLogFile(); } catch (...) { ignoreException(); }
 }