summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripts/functions2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/functions b/scripts/functions
index 8665346..91ec217 100644
--- a/scripts/functions
+++ b/scripts/functions
@@ -14,7 +14,7 @@ CT_OnError() {
# To avoid printing the backtace for each sub-shell
# up to the top-level, just remember we've dumped it
if [ ! -f "${CT_WORK_DIR}/backtrace" ]; then
- touch "${CT_WORK_DIR}/backtrace"
+ [ -d "${CT_WORK_DIR}" ] && touch "${CT_WORK_DIR}/backtrace"
# Print steps backtrace
step_depth=${CT_STEP_COUNT}