Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(134)

Side by Side Diff: minidump/minidump_system_info_writer.cc

Issue 1120383003: Get generate_dump compiling on Windows (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@tools
Patch Set: fix mac; no implicit conversion to std::string for StringPiece Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « compat/win/sys/types.h ('k') | tools/crashpad_database_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Crashpad Authors. All rights reserved. 1 // Copyright 2014 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 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 } 147 }
148 } else if (cpu_architecture == kMinidumpCPUArchitectureAMD64) { 148 } else if (cpu_architecture == kMinidumpCPUArchitectureAMD64) {
149 SetCPUOtherFeatures(AMD64FeaturesFromSystemSnapshot(system_snapshot), 0); 149 SetCPUOtherFeatures(AMD64FeaturesFromSystemSnapshot(system_snapshot), 0);
150 } 150 }
151 151
152 MinidumpOS operating_system; 152 MinidumpOS operating_system;
153 switch (system_snapshot->GetOperatingSystem()) { 153 switch (system_snapshot->GetOperatingSystem()) {
154 case SystemSnapshot::kOperatingSystemMacOSX: 154 case SystemSnapshot::kOperatingSystemMacOSX:
155 operating_system = kMinidumpOSMacOSX; 155 operating_system = kMinidumpOSMacOSX;
156 break; 156 break;
157 case SystemSnapshot::kOperatingSystemWindows:
158 operating_system = kMinidumpOSWin32NT;
159 break;
157 default: 160 default:
158 NOTREACHED(); 161 NOTREACHED();
159 operating_system = kMinidumpOSUnknown; 162 operating_system = kMinidumpOSUnknown;
160 break; 163 break;
161 } 164 }
162 SetOS(operating_system); 165 SetOS(operating_system);
163 166
164 SetOSType(system_snapshot->OSServer() ? kMinidumpOSTypeServer 167 SetOSType(system_snapshot->OSServer() ? kMinidumpOSTypeServer
165 : kMinidumpOSTypeWorkstation); 168 : kMinidumpOSTypeWorkstation);
166 169
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 DCHECK_EQ(state(), kStateWritable); 290 DCHECK_EQ(state(), kStateWritable);
288 291
289 return file_writer->Write(&system_info_, sizeof(system_info_)); 292 return file_writer->Write(&system_info_, sizeof(system_info_));
290 } 293 }
291 294
292 MinidumpStreamType MinidumpSystemInfoWriter::StreamType() const { 295 MinidumpStreamType MinidumpSystemInfoWriter::StreamType() const {
293 return kMinidumpStreamTypeSystemInfo; 296 return kMinidumpStreamTypeSystemInfo;
294 } 297 }
295 298
296 } // namespace crashpad 299 } // namespace crashpad
OLDNEW
« no previous file with comments | « compat/win/sys/types.h ('k') | tools/crashpad_database_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698