From ea27e95f489fbb29cedad74788ee607b331f8a2f Mon Sep 17 00:00:00 2001 From: Alexander von Gluck IV Date: Mon, 24 Jun 2013 15:22:37 -0500 Subject: [PATCH] debuganalyzer: Fix double free. CID 992566 * RemoveRow frees row, thus the delete isn't needed. --- src/apps/debuganalyzer/gui/table/Table.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/apps/debuganalyzer/gui/table/Table.cpp b/src/apps/debuganalyzer/gui/table/Table.cpp index 2eb7b93cc3..2b2b9bcf8a 100644 --- a/src/apps/debuganalyzer/gui/table/Table.cpp +++ b/src/apps/debuganalyzer/gui/table/Table.cpp @@ -640,10 +640,8 @@ Table::TableRowsRemoved(TableModel* model, int32 rowIndex, int32 count) } for (int32 i = rowIndex + count - 1; i >= rowIndex; i--) { - if (BRow* row = fRows.RemoveItemAt(i)) { + if (BRow* row = fRows.RemoveItemAt(i)) RemoveRow(row); - delete row; - } } // re-index the subsequent rows