| Index: content/browser/download/base_file_win.cc
|
| diff --git a/content/browser/download/base_file_win.cc b/content/browser/download/base_file_win.cc
|
| index 398e5fc214ff4c80201048dbe376435d9afe0fcb..4bddcd88bf15f9f964ce170c1ed4dfb731a7619d 100644
|
| --- a/content/browser/download/base_file_win.cc
|
| +++ b/content/browser/download/base_file_win.cc
|
| @@ -5,9 +5,12 @@
|
| #include "content/browser/download/base_file.h"
|
|
|
| #include <windows.h>
|
| +#include <cguid.h>
|
| +#include <objbase.h>
|
| #include <shellapi.h>
|
|
|
| #include "base/file_util.h"
|
| +#include "base/guid.h"
|
| #include "base/metrics/histogram.h"
|
| #include "base/strings/utf_string_conversions.h"
|
| #include "base/threading/thread_restrictions.h"
|
| @@ -326,7 +329,16 @@ DownloadInterruptReason BaseFile::AnnotateWithSourceInformation() {
|
|
|
| bound_net_log_.BeginEvent(net::NetLog::TYPE_DOWNLOAD_FILE_ANNOTATED);
|
| DownloadInterruptReason result = DOWNLOAD_INTERRUPT_REASON_NONE;
|
| - HRESULT hr = ScanAndSaveDownloadedFile(full_path_, source_url_);
|
| + std::string braces_guid = "{" + client_guid_ + "}";
|
| + GUID guid = GUID_NULL;
|
| + if (!client_guid_.empty() && base::IsValidGUID(client_guid_)) {
|
| + HRESULT hr = CLSIDFromString(
|
| + base::UTF8ToUTF16(braces_guid).c_str(), &guid);
|
| + if (FAILED(hr))
|
| + guid = GUID_NULL;
|
| + }
|
| +
|
| + HRESULT hr = AVScanFile(full_path_, source_url_.spec(), guid);
|
|
|
| // If the download file is missing after the call, then treat this as an
|
| // interrupted download.
|
|
|