mirror of
https://git.suyu.dev/suyu/breakpad.git
synced 2025-12-26 09:14:58 +01:00
Use stdint types everywhere
R=mark at https://breakpad.appspot.com/535002/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1121 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
c02002a581
commit
aeffe1056f
117 changed files with 1385 additions and 1379 deletions
|
|
@ -50,8 +50,8 @@ namespace google_breakpad {
|
|||
|
||||
// The cutoff that we use to judge if and address is likely an offset
|
||||
// from various interesting addresses.
|
||||
static const u_int64_t kProbableNullOffset = 4096;
|
||||
static const u_int64_t kProbableStackOffset = 8192;
|
||||
static const uint64_t kProbableNullOffset = 4096;
|
||||
static const uint64_t kProbableStackOffset = 8192;
|
||||
|
||||
// The various cutoffs for the different ratings.
|
||||
static const size_t kHighCutoff = 100;
|
||||
|
|
@ -98,14 +98,14 @@ ExploitabilityRating ExploitabilityWin::CheckPlatformExploitability() {
|
|||
BPLOG(INFO) << "Minidump memory segments not available.";
|
||||
memory_available = false;
|
||||
}
|
||||
u_int64_t address = process_state_->crash_address();
|
||||
u_int32_t exception_code = raw_exception->exception_record.exception_code;
|
||||
uint64_t address = process_state_->crash_address();
|
||||
uint32_t exception_code = raw_exception->exception_record.exception_code;
|
||||
|
||||
u_int32_t exploitability_weight = 0;
|
||||
uint32_t exploitability_weight = 0;
|
||||
|
||||
u_int64_t stack_ptr = 0;
|
||||
u_int64_t instruction_ptr = 0;
|
||||
u_int64_t this_ptr = 0;
|
||||
uint64_t stack_ptr = 0;
|
||||
uint64_t instruction_ptr = 0;
|
||||
uint64_t this_ptr = 0;
|
||||
|
||||
switch (context->GetContextCPU()) {
|
||||
case MD_CONTEXT_X86:
|
||||
|
|
@ -211,14 +211,14 @@ ExploitabilityRating ExploitabilityWin::CheckPlatformExploitability() {
|
|||
context->GetContextCPU() == MD_CONTEXT_X86 &&
|
||||
(bad_read || bad_write)) {
|
||||
// Perform checks related to memory around instruction pointer.
|
||||
u_int32_t memory_offset =
|
||||
uint32_t memory_offset =
|
||||
instruction_ptr - instruction_region->GetBase();
|
||||
u_int32_t available_memory =
|
||||
uint32_t available_memory =
|
||||
instruction_region->GetSize() - memory_offset;
|
||||
available_memory = available_memory > kDisassembleBytesBeyondPC ?
|
||||
kDisassembleBytesBeyondPC : available_memory;
|
||||
if (available_memory) {
|
||||
const u_int8_t *raw_memory =
|
||||
const uint8_t *raw_memory =
|
||||
instruction_region->GetMemory() + memory_offset;
|
||||
DisassemblerX86 disassembler(raw_memory,
|
||||
available_memory,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue