From 12554268d2c24f18695aa990560509d26e647657 Mon Sep 17 00:00:00 2001 From: Lieven Hey Date: Mon, 13 May 2024 12:54:20 +0200 Subject: [PATCH] fix: crash if samples have different amount of costs associated If we have a recording with the following layout: A B C where A: part where function f is accessed B: list samples C: part where function g is accessed then f won't have the lost events cost while g does. This will cause a crash when the model tries to access it fixes: #629 --- src/models/callercalleemodel.h | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/src/models/callercalleemodel.h b/src/models/callercalleemodel.h index 98d3e4797..7e2d1349b 100644 --- a/src/models/callercalleemodel.h +++ b/src/models/callercalleemodel.h @@ -263,16 +263,26 @@ class LocationCostModelImpl : public HashModel= NUM_BASE_COLUMNS) { column -= NUM_BASE_COLUMNS; if (column >= m_totalCosts.numTypes()) { @@ -289,10 +299,10 @@ class LocationCostModelImpl : public HashModel