| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "device/sensors/public/cpp/shared_memory_seqlock_reader.h" | 5 #include "services/device/public/cpp/sensors/shared_memory_seqlock_reader.h" |
| 6 | 6 |
| 7 namespace device { | 7 namespace device { |
| 8 namespace internal { | 8 namespace internal { |
| 9 | 9 |
| 10 SharedMemorySeqLockReaderBase::SharedMemorySeqLockReaderBase() {} | 10 SharedMemorySeqLockReaderBase::SharedMemorySeqLockReaderBase() {} |
| 11 | 11 |
| 12 SharedMemorySeqLockReaderBase::~SharedMemorySeqLockReaderBase() {} | 12 SharedMemorySeqLockReaderBase::~SharedMemorySeqLockReaderBase() {} |
| 13 | 13 |
| 14 void* SharedMemorySeqLockReaderBase::InitializeSharedMemory( | 14 void* SharedMemorySeqLockReaderBase::InitializeSharedMemory( |
| 15 base::SharedMemoryHandle shared_memory_handle, | 15 base::SharedMemoryHandle shared_memory_handle, |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 return false; | 53 return false; |
| 54 } | 54 } |
| 55 | 55 |
| 56 // New data was read successfully, copy it into the output buffer. | 56 // New data was read successfully, copy it into the output buffer. |
| 57 memcpy(final, temp, size); | 57 memcpy(final, temp, size); |
| 58 return true; | 58 return true; |
| 59 } | 59 } |
| 60 | 60 |
| 61 } // namespace internal | 61 } // namespace internal |
| 62 } // namespace device | 62 } // namespace device |
| OLD | NEW |