From a7c05e5e113e9b10e09d395cfc0686ded9356453 Mon Sep 17 00:00:00 2001 From: hjk Date: Fri, 6 Mar 2020 10:15:26 +0100 Subject: Debugger: Invalidate disassembler cache index after using it Not before. Amends b3812bf94f. Change-Id: I3f8dd9f23adbbd56bb0d5d76a80a90fd9b7030b5 Reviewed-by: Christian Stenger --- src/plugins/debugger/disassembleragent.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/debugger/disassembleragent.cpp b/src/plugins/debugger/disassembleragent.cpp index d8a083b8d5..ff958b5d7a 100644 --- a/src/plugins/debugger/disassembleragent.cpp +++ b/src/plugins/debugger/disassembleragent.cpp @@ -238,8 +238,8 @@ void DisassemblerAgent::setLocation(const Location &loc) // Refresh when not displaying a function and there is not sufficient // context left past the address. if (d->cache.at(index).first.endAddress - loc.address() < 24) { - index = -1; d->cache.removeAt(index); + index = -1; } } if (index != -1) { -- cgit v1.2.1