| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/sync/base/attachment_id_proto.h" | 5 #include "components/sync/base/attachment_id_proto.h" |
| 6 | 6 |
| 7 #include <stddef.h> | |
| 8 #include <stdint.h> | |
| 9 | |
| 10 #include <string> | 7 #include <string> |
| 11 | 8 |
| 12 #include "base/guid.h" | 9 #include "base/guid.h" |
| 13 #include "base/logging.h" | 10 #include "base/logging.h" |
| 14 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
| 15 | 12 |
| 16 namespace syncer { | 13 namespace syncer { |
| 17 | 14 |
| 18 sync_pb::AttachmentIdProto CreateAttachmentIdProto(size_t size, | 15 sync_pb::AttachmentIdProto CreateAttachmentIdProto(size_t size, |
| 19 uint32_t crc32c) { | 16 uint32_t crc32c) { |
| (...skipping 13 matching lines...) Expand all Loading... |
| 33 sync_pb::AttachmentMetadata result; | 30 sync_pb::AttachmentMetadata result; |
| 34 for (int i = 0; i < ids.size(); ++i) { | 31 for (int i = 0; i < ids.size(); ++i) { |
| 35 sync_pb::AttachmentMetadataRecord* record = result.add_record(); | 32 sync_pb::AttachmentMetadataRecord* record = result.add_record(); |
| 36 *record->mutable_id() = ids.Get(i); | 33 *record->mutable_id() = ids.Get(i); |
| 37 record->set_is_on_server(true); | 34 record->set_is_on_server(true); |
| 38 } | 35 } |
| 39 return result; | 36 return result; |
| 40 } | 37 } |
| 41 | 38 |
| 42 } // namespace syncer | 39 } // namespace syncer |
| OLD | NEW |