From 7d5ce06cbe35f3f818695c87e5b0f42172ee3784 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 9 Apr 2017 02:01:05 -0700 Subject: Pull the error reporting into {read,save}_filter_list. Change-Id: I4d9582661f2f1728d400eeb2a1b1dea98f32ce7f Reviewed-on: https://code.wireshark.org/review/20982 Reviewed-by: Guy Harris --- ui/qt/capture_filter_edit.cpp | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'ui/qt/capture_filter_edit.cpp') diff --git a/ui/qt/capture_filter_edit.cpp b/ui/qt/capture_filter_edit.cpp index 89e2bd8df4..083b1df119 100644 --- a/ui/qt/capture_filter_edit.cpp +++ b/ui/qt/capture_filter_edit.cpp @@ -506,18 +506,7 @@ void CaptureFilterEdit::removeFilter() } } - char *f_path; - int f_save_errno; - - save_filter_list(CFILTER_LIST, &f_path, &f_save_errno); - if (f_path != NULL) { - // We had an error saving the filter. - QString warning_title = tr("Unable to save capture filter settings."); - QString warning_msg = tr("Could not save to your capture filter file\n\"%1\": %2.").arg(f_path).arg(g_strerror(f_save_errno)); - - QMessageBox::warning(this, warning_title, warning_msg, QMessageBox::Ok); - g_free(f_path); - } + save_filter_list(CFILTER_LIST); updateBookmarkMenu(); } -- cgit v1.2.1