diff options
author | Dave Reisner <dreisner@archlinux.org> | 2017-04-06 10:55:31 -0400 |
---|---|---|
committer | Dave Reisner <dreisner@archlinux.org> | 2017-04-06 10:55:31 -0400 |
commit | 72a724a754fc53adc6068074d3fd2ffa268980d3 (patch) | |
tree | 78aa0f97bb2bd6be21f1d471d8c2874729da8ccd | |
parent | 4a39f5474ccd54e48de8d55a30970e8a3d599b65 (diff) | |
download | asp32-72a724a754fc53adc6068074d3fd2ffa268980d3.tar.xz |
make ASPCACHE dir creation fatal
-rw-r--r-- | asp.in | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -128,9 +128,11 @@ initialize() { mkdir -p "$ASPROOT" fi - cd "$ASPROOT" || log_fatal "ASPROOT ($ASPROOT) does not exist!" + cd "$ASPROOT" || log_fatal "ASPROOT (%s) does not exist!" "$ASPROOT" - [[ -d $ASPCACHE ]] || mkdir -p "$ASPCACHE" + if [[ ! -d $ASPCACHE ]] && ! mkdir -p "$ASPCACHE"; then + log_fatal 'failed to create ASPCACHE (%s)' "$ASPCACHE" + fi [[ -f .asp ]] && return 0 |