Qt: Check for valid color filter before use

Not all packet have a color filter, so check for this before use.

Bug: 12065
Change-Id: Ieed8d369342bde50fe8a1562be9379695da9fbaa
Reviewed-on: https://code.wireshark.org/review/15677
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
This commit is contained in:
Stig Bjørlykke 2016-06-01 13:00:30 +02:00 committed by Gerald Combs
parent 76ef2d2a3d
commit 374266296d
1 changed files with 4 additions and 2 deletions

View File

@ -109,8 +109,10 @@ seq_analysis_frame_packet( void *ptr, packet_info *pinfo, epan_dissect_t *edt _U
sai->frame_number = pinfo->num;
sai->bg_color = color_t_to_rgb(&pinfo->fd->color_filter->bg_color);
sai->fg_color = color_t_to_rgb(&pinfo->fd->color_filter->fg_color);
if (pinfo->fd->color_filter) {
sai->bg_color = color_t_to_rgb(&pinfo->fd->color_filter->bg_color);
sai->fg_color = color_t_to_rgb(&pinfo->fd->color_filter->fg_color);
}
sai->port_src=pinfo->srcport;
sai->port_dst=pinfo->destport;