Clear cache only for failed downloads

Signed-off-by: Sven Strickroth <email@cs-ware.de>