Stop crash when DownloadManager sends STATUS_FAILED and add logging for reason code