Multicast Statistics Dialog: Clear list when redrawing

The multicast statistics tap provides a continually updating list which the draw function just has to iterate through.

Bug: 15271
Change-Id: I270e7ca9460ec9568756b6c8d98f4f17653c8cad
Reviewed-on: https://code.wireshark.org/review/30976
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot
Reviewed-by: Michael Mann <mmann78@netscape.net>
This commit is contained in:
Michael Mann 2018-12-09 09:27:31 -05:00
parent a621fde383
commit 96c52c1a0f
1 changed files with 3 additions and 0 deletions

View File

@ -276,6 +276,9 @@ void MulticastStatisticsDialog::tapDraw(mcaststream_tapinfo_t *tapinfo)
MulticastStatisticsDialog *ms_dlg = dynamic_cast<MulticastStatisticsDialog *>((MulticastStatisticsDialog*)tapinfo->user_data);
if (!ms_dlg || !ms_dlg->statsTreeWidget()) return;
//Clear the tree because the list always starts from the beginning
ms_dlg->statsTreeWidget()->clear();
// Add missing rows and update stats
int cur_row = 0;
for (GList *cur = g_list_first(tapinfo->strinfo_list); cur; cur = g_list_next(cur)) {