- Electron version: 1.2.4 (May Be All Version has the issue)
- Operating system: MAC OS X 10.10.5 (May Be All OS)

i set the `DownloadItem.setSavePath` but if the target resource return 404 status from server, then the save dialog prompt.
### Steps to reproduce

Merged in from #6957
1. Disconnect from the network
2. initiate a download using mainWindow.webContents.downloadURL(url);
3. call item.setSavePath(path) in the will-download handler

Result:
The browser will show a save dialog.

Expected result:
No save dialog, just an updated or done callback on the item

It appears that the code that notices a save path has been set and prevents the dialog from coming up doesn't happen when the download fails.

atom/browser/atom_download_manager_delegate.cc
#include "atom/browser/atom_download_manager_delegate.h"
#include <string>
#include "atom/browser/api/atom_api_download_item.h"
#include "atom/browser/atom_browser_context.h"
#include "atom/browser/native_window.h"
#include "atom/browser/ui/file_dialog.h"
#include "base/bind.h"
#include "base/files/file_util.h"
#include "components/prefs/pref_service.h"
#include "chrome/common/pref_names.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/download_manager.h"
#include "net/base/filename_util.h"
namespace atom {
AtomDownloadManagerDelegate::AtomDownloadManagerDelegate(
    content::DownloadManager* manager)
    : download_manager_(manager),
      weak_ptr_factory_(this) {}
AtomDownloadManagerDelegate::~AtomDownloadManagerDelegate() {