aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/google_breakpad/processor/proc_maps_linux.h4
-rw-r--r--src/processor/proc_maps_linux.cc8
2 files changed, 6 insertions, 6 deletions
diff --git a/src/google_breakpad/processor/proc_maps_linux.h b/src/google_breakpad/processor/proc_maps_linux.h
index 22f9f6a4..b8e6eb92 100644
--- a/src/google_breakpad/processor/proc_maps_linux.h
+++ b/src/google_breakpad/processor/proc_maps_linux.h
@@ -23,8 +23,8 @@ struct MappedMemoryRegion {
};
// The address range [start,end) of mapped memory.
- uintptr_t start;
- uintptr_t end;
+ uint64_t start;
+ uint64_t end;
// Byte offset into |path| of the range mapped into memory.
uint64_t offset;
diff --git a/src/processor/proc_maps_linux.cc b/src/processor/proc_maps_linux.cc
index 1954cc86..3ba767f3 100644
--- a/src/processor/proc_maps_linux.cc
+++ b/src/processor/proc_maps_linux.cc
@@ -61,10 +61,10 @@ bool ParseProcMaps(const std::string& input,
// The final %n term captures the offset in the input string, which is used
// to determine the path name. It *does not* increment the return value.
// Refer to man 3 sscanf for details.
- if (sscanf(line, "%lx-%lx %4c %lx %hhx:%hhx %ld %n",
- &region.start, &region.end, permissions, &region.offset,
- &region.major_device, &region.minor_device, &region.inode,
- &path_index) < 7) {
+ if (sscanf(line, "%" SCNx64 "-%" SCNx64 " %4c %" SCNx64" %hhx:%hhx %"
+ SCNd64 " %n", &region.start, &region.end, permissions,
+ &region.offset, &region.major_device, &region.minor_device,
+ &region.inode, &path_index) < 7) {
BPLOG(ERROR) << "sscanf failed for line: " << line;
return false;
}