OLD | NEW |
1 // Copyright 2015 The Crashpad Authors. All rights reserved. | 1 // Copyright 2015 The Crashpad Authors. All rights reserved. |
2 // | 2 // |
3 // Licensed under the Apache License, Version 2.0 (the "License"); | 3 // Licensed under the Apache License, Version 2.0 (the "License"); |
4 // you may not use this file except in compliance with the License. | 4 // you may not use this file except in compliance with the License. |
5 // You may obtain a copy of the License at | 5 // You may obtain a copy of the License at |
6 // | 6 // |
7 // http://www.apache.org/licenses/LICENSE-2.0 | 7 // http://www.apache.org/licenses/LICENSE-2.0 |
8 // | 8 // |
9 // Unless required by applicable law or agreed to in writing, software | 9 // Unless required by applicable law or agreed to in writing, software |
10 // distributed under the License is distributed on an "AS IS" BASIS, | 10 // distributed under the License is distributed on an "AS IS" BASIS, |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
291 | 291 |
292 for (uint64_t cur = crashpad_info.user_data_minidump_stream_head; cur;) { | 292 for (uint64_t cur = crashpad_info.user_data_minidump_stream_head; cur;) { |
293 internal::UserDataMinidumpStreamListEntry list_entry; | 293 internal::UserDataMinidumpStreamListEntry list_entry; |
294 if (!process_reader_->ReadMemory( | 294 if (!process_reader_->ReadMemory( |
295 cur, sizeof(list_entry), &list_entry)) { | 295 cur, sizeof(list_entry), &list_entry)) { |
296 LOG(WARNING) << "could not read user data stream entry from " | 296 LOG(WARNING) << "could not read user data stream entry from " |
297 << base::UTF16ToUTF8(name_); | 297 << base::UTF16ToUTF8(name_); |
298 return; | 298 return; |
299 } | 299 } |
300 | 300 |
301 scoped_ptr<internal::MemorySnapshotWin> memory( | 301 std::unique_ptr<internal::MemorySnapshotWin> memory( |
302 new internal::MemorySnapshotWin()); | 302 new internal::MemorySnapshotWin()); |
303 memory->Initialize( | 303 memory->Initialize( |
304 process_reader_, list_entry.base_address, list_entry.size); | 304 process_reader_, list_entry.base_address, list_entry.size); |
305 streams->push_back( | 305 streams->push_back( |
306 new UserMinidumpStream(list_entry.stream_type, memory.release())); | 306 new UserMinidumpStream(list_entry.stream_type, memory.release())); |
307 | 307 |
308 cur = list_entry.next; | 308 cur = list_entry.next; |
309 } | 309 } |
310 } | 310 } |
311 | 311 |
312 } // namespace internal | 312 } // namespace internal |
313 } // namespace crashpad | 313 } // namespace crashpad |
OLD | NEW |