summaryrefslogtreecommitdiffstats
path: root/fb.in
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@server-speed.net>2011-11-24 17:58:44 +0100
committerFlorian Pritz <bluewind@server-speed.net>2011-11-24 17:58:44 +0100
commitfd4599262410cc0165a6c17fb624057a6b82d2b0 (patch)
tree196c4c55ee84484de8c8198a6ced6c19ab067477 /fb.in
parent22cf17831c310acd308e1fa3656169ccc7b3986e (diff)
remove fetched files even when upload failed
If the upload failed and the user supplied multiple URLs, we will find those on the next run and try to upload them again. Signed-off-by: Florian Pritz <bluewind@server-speed.net>
Diffstat (limited to 'fb.in')
-rw-r--r--fb.in5
1 files changed, 2 insertions, 3 deletions
diff --git a/fb.in b/fb.in
index 68adf77..ead38ef 100644
--- a/fb.in
+++ b/fb.in
@@ -199,11 +199,10 @@ else
continue
fi
for f in *; do
- if do_upload "$f"; then
- rm -f -- "$f"
- else
+ if ! do_upload "$f"; then
EXITCODE=1
fi
+ rm -f -- "$f"
done
else
do_upload "$i" || EXITCODE=1