From c3e6a194674913546de1a659e3916b89231d7b28 Mon Sep 17 00:00:00 2001 From: Clinton Hall Date: Wed, 20 Mar 2013 20:23:19 -0700 Subject: [PATCH] add escape to cd command fixes #87 --- nzbget-postprocessing-files/10.0/nzbget-postprocess.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nzbget-postprocessing-files/10.0/nzbget-postprocess.sh b/nzbget-postprocessing-files/10.0/nzbget-postprocess.sh index 87134418..19bef1e0 100755 --- a/nzbget-postprocessing-files/10.0/nzbget-postprocess.sh +++ b/nzbget-postprocessing-files/10.0/nzbget-postprocess.sh @@ -300,7 +300,7 @@ ConfigDir="${NZBOP_CONFIGFILE%/*}" tmplog="$ConfigDir/$tmp.log" echo "[INFO] Post-Process: Post-processing script successfully started" | tee $tmplog -cd "$NZBPP_DIRECTORY" +cd "$NZBPP_DIRECTORY" || (echo "[ERROR] Post-Process: Nothing to post-process: destination directory $NZBPP_DIRECTORY isn't accessible" && do_exit $POSTPROCESS_ERROR) # Determine the location of configuration file (it must be stored in # the directory with nzbget.conf).