summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/source/Target/Memory.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/source/Target/Memory.cpp b/lldb/source/Target/Memory.cpp
index fac5e43c286..7433317bf8c 100644
--- a/lldb/source/Target/Memory.cpp
+++ b/lldb/source/Target/Memory.cpp
@@ -146,7 +146,7 @@ size_t MemoryCache::Read(addr_t addr, void *dst, size_t dst_len,
}
AddrRange chunk_range(pos->first, pos->second->GetByteSize());
if (chunk_range.Contains(read_range)) {
- memcpy(dst, pos->second->GetBytes() + addr - chunk_range.GetRangeBase(),
+ memcpy(dst, pos->second->GetBytes() + (addr - chunk_range.GetRangeBase()),
dst_len);
return dst_len;
}
OpenPOWER on IntegriCloud