summaryrefslogtreecommitdiff
path: root/ui/tap-sequence-analysis.c
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2014-11-18 13:13:35 -0800
committerGerald Combs <gerald@wireshark.org>2014-11-18 23:37:35 +0000
commitcfa0e5fd53870f297dbec2f0a9aef896ba11f7c5 (patch)
treee457042154a6db0a30043091cd67a0868741d453 /ui/tap-sequence-analysis.c
parentdc5b8f1093c00e759c842257b1706eab4c08f629 (diff)
downloadwireshark-cfa0e5fd53870f297dbec2f0a9aef896ba11f7c5.tar.gz
voip_calls: Regression fixes.
Fix struct initialization logic. Clear a GQueue instead of deleting it. Don't crash if we have no sequence diagram items. Make sure we show all flows and not just invites. Zero allocated memory in a couple of places. Change-Id: Ia5bb3ba57cf625de4b554b354e098aa0361dff28 Reviewed-on: https://code.wireshark.org/review/5390 Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'ui/tap-sequence-analysis.c')
-rw-r--r--ui/tap-sequence-analysis.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/tap-sequence-analysis.c b/ui/tap-sequence-analysis.c
index 695dbc96a9..b207492f8a 100644
--- a/ui/tap-sequence-analysis.c
+++ b/ui/tap-sequence-analysis.c
@@ -362,7 +362,7 @@ static gint add_or_get_node(seq_analysis_info_t *sainfo, address *node) {
if ( CMP_ADDRESS(&(sainfo->nodes[i]), node) == 0 ) return i; /* it is in the array */
}
- if (i == MAX_NUM_NODES) {
+ if (i >= MAX_NUM_NODES) {
return NODE_OVERFLOW;
} else {
sainfo->num_nodes++;
@@ -394,7 +394,7 @@ sequence_analysis_get_nodes(seq_analysis_info_t *sainfo)
{
struct sainfo_counter sc = {sainfo, 0};
- /* fill the node array */
+ /* Fill the node array */
g_queue_foreach(sainfo->items, sequence_analysis_get_nodes_item_proc, &sc);
return sc.num_items;