forked from osmocom/wireshark
Move what capture_info_close() does into its only caller.
Change-Id: If9539142100fb2079cbbe247d8975778b183ece8 Reviewed-on: https://code.wireshark.org/review/26235 Reviewed-by: Guy Harris <guy@alum.mit.edu>
This commit is contained in:
parent
c7872232e5
commit
07cb624e48
|
@ -70,15 +70,6 @@ void capture_info_new_packets(int to_read, info_data_t* cap_info)
|
|||
capture_info_ui_update(&cap_info->ui);
|
||||
}
|
||||
|
||||
|
||||
/* close the info */
|
||||
void capture_info_close(info_data_t* cap_info)
|
||||
{
|
||||
capture_info_ui_destroy(&cap_info->ui);
|
||||
if(cap_info->wtap)
|
||||
wtap_close(cap_info->wtap);
|
||||
}
|
||||
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
|
||||
/*
|
||||
|
|
|
@ -52,9 +52,6 @@ typedef struct _info_data {
|
|||
/* new packets arrived - read from wtap, count */
|
||||
extern void capture_info_new_packets(int to_read, info_data_t* cap_info);
|
||||
|
||||
/* close the info - close wtap, destroy dialog */
|
||||
extern void capture_info_close(info_data_t* cap_info);
|
||||
|
||||
/** Create the capture info dialog */
|
||||
extern void
|
||||
capture_info_ui_create(capture_info *cinfo, capture_session *cap_session);
|
||||
|
|
|
@ -710,8 +710,11 @@ capture_input_closed(capture_session *cap_session, gchar *msg)
|
|||
}
|
||||
}
|
||||
|
||||
if(capture_opts->show_info)
|
||||
capture_info_close(cap_session->cap_data_info);
|
||||
if(capture_opts->show_info) {
|
||||
capture_info_ui_destroy(&cap_session->cap_data_info->ui);
|
||||
if(cap_session->cap_data_info->wtap)
|
||||
wtap_close(cap_session->cap_data_info->wtap);
|
||||
}
|
||||
|
||||
cap_session->state = CAPTURE_STOPPED;
|
||||
|
||||
|
|
Loading…
Reference in New Issue