mirror of
https://github.com/chromium/crashpad.git
synced 2024-12-27 23:41:02 +08:00
win: Locally disable allocation alignment warning
A (somewhat cursory) inspection leads me to believe that there's no particular alignment requirements for this object at this location, so this warning can be ignored. d:\src\crashpad\crashpad\minidump\minidump_context_writer.cc(43) : error C2220: warning treated as error - no 'object' file generated d:\src\crashpad\crashpad\minidump\minidump_context_writer.cc(43) : warning C4316: 'crashpad::MinidumpContextAMD64Writer' : object allocated on the heap may not be aligned 16 R=mark@chromium.org BUG=crashpad:1 Review URL: https://codereview.chromium.org/893393002
This commit is contained in:
parent
74a34e9c4b
commit
2b46aaabda
@ -39,8 +39,16 @@ scoped_ptr<MinidumpContextWriter> MinidumpContextWriter::CreateFromSnapshot(
|
||||
}
|
||||
|
||||
case kCPUArchitectureX86_64: {
|
||||
#if defined(COMPILER_MSVC) && defined(ARCH_CPU_X86)
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4316) // Object allocated on the heap may not be 16
|
||||
// byte aligned.
|
||||
#endif
|
||||
MinidumpContextAMD64Writer* context_amd64 =
|
||||
new MinidumpContextAMD64Writer();
|
||||
#if defined(COMPILER_MSVC) && defined(ARCH_CPU_X86)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
context.reset(context_amd64);
|
||||
context_amd64->InitializeFromSnapshot(context_snapshot->x86_64);
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user