| Index: sync/internal_api/attachments/fake_attachment_downloader.cc
|
| diff --git a/sync/internal_api/attachments/fake_attachment_downloader.cc b/sync/internal_api/attachments/fake_attachment_downloader.cc
|
| index 1f2795e7dfdd849c42e122f13de4c907068555a3..92124d045d76c6cc1d2fc30d8ac6804554885c2e 100644
|
| --- a/sync/internal_api/attachments/fake_attachment_downloader.cc
|
| +++ b/sync/internal_api/attachments/fake_attachment_downloader.cc
|
| @@ -6,6 +6,7 @@
|
|
|
| #include "base/bind.h"
|
| #include "base/message_loop/message_loop.h"
|
| +#include "sync/internal_api/public/attachments/attachment_util.h"
|
|
|
| namespace syncer {
|
|
|
| @@ -24,8 +25,9 @@ void FakeAttachmentDownloader::DownloadAttachment(
|
| // attachment.
|
| scoped_refptr<base::RefCountedMemory> data(new base::RefCountedBytes());
|
| scoped_ptr<Attachment> attachment;
|
| + uint32_t crc = ComputeCrc32c(data);
|
| attachment.reset(
|
| - new Attachment(Attachment::CreateWithId(attachment_id, data)));
|
| + new Attachment(Attachment::RestoreExisting(attachment_id, data, crc)));
|
| base::MessageLoop::current()->PostTask(
|
| FROM_HERE,
|
| base::Bind(callback, DOWNLOAD_SUCCESS, base::Passed(&attachment)));
|
|
|