[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[dsdp-tcf-dev] [Bug 327507] New: MemoryProxy not properly processing non-zero offsets in range containing multiple entries
|
https://bugs.eclipse.org/bugs/show_bug.cgi?id=327507
Product/Component: Target Management / TCF
Summary: MemoryProxy not properly processing non-zero offsets
in range containing multiple entries
Classification: DSDP
Product: Target Management
Version: 3.3
Platform: All
OS/Version: All
Status: NEW
Severity: critical
Priority: P3
Component: TCF
AssignedTo: dsdp.tm.tcf-inbox@xxxxxxxxxxx
ReportedBy: kirk.beitz@xxxxxxxxx
QAContact: martin.oberhuber@xxxxxxxxxxxxx
Kirk Beitz <kirk.beitz@xxxxxxxxx> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #180635| |review?
Flag| |
Created an attachment (id=180635)
--> (https://bugs.eclipse.org/bugs/attachment.cgi?id=180635)
bugfix to subtract original address from error address to get offset (includes
changes found in patch in Bug 326270)
org.eclipse.tm.internal.tcf.services.remote.MemoryProxy.MemoryErrorReport.MemoryErrorReport()
appears to contain a bug w.r.t. the processing of addresses that are offset
from the originally requested address passed as a parameter to
org.eclipse.tm.internal.tcf.services.remote.MemoryProxy.MemContext.get() .
this snippet of code (also seen in the attached patch) appears to be incorrect:
BigInteger addr_bi = addr instanceof BigInteger ?
(BigInteger)addr : new BigInteger(addr.toString());
for (Map<String,Object> m : c) {
Range r = new Range();
Number x = (Number)m.get(RANGE_KEY_ADDR);
BigInteger y = x instanceof BigInteger ?
(BigInteger)x : new BigInteger(x.toString());
this call =======> r.offs = y.subtract(addr_bi).intValue();
r.size = ((Number)m.get(RANGE_KEY_SIZE)).intValue();
r.stat = ((Number)m.get(RANGE_KEY_STAT)).intValue();
r.msg = Command.toErrorString(m.get(RANGE_KEY_MSG));
causes this =====> assert r.offs >= 0;
to fire the assert r.size >= 0;
second time this.ranges[n++] = r;
thru the loop }
it would seem to be more appropriate to have it be
better ==========> r.offs = addr_bi.subtract(y).intValue();
making this a critical due to it blocking the ability to implement an agent
mechanism to send back address blocks in a single TCF message that are at
appropriate offests.
--
Configure bugmail: https://bugs.eclipse.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.