[applied] comparison: Always apply filters on the diff graph

Message ID 87a5t0gi0j.fsf@redhat.com
State New
Headers
Series [applied] comparison: Always apply filters on the diff graph |

Commit Message

Dodji Seketeli Oct. 3, 2023, 9:41 a.m. UTC
  Hello,

When looking at something else, I noticed that
diff_context::maybe_apply_filters doesn't apply the filters (i.e, the
various passes) on the diff graph if all the categories of changes are
allowed, typically when --harmless is passed to abidiff.

This is wrong because even if all the categories are allowed, the
changes carried by nodes of the diff graph should still be
categorized.  This was an early optimization dating back from the
times where the filtering was slow.

	* src/abg-comparison.cc (diff_context::maybe_apply_filters): Do
	not get out when all the categories of diff changes are allowed.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
Applied to master.
---
 src/abg-comparison.cc | 3 ---
 1 file changed, 3 deletions(-)
  

Patch

diff --git a/src/abg-comparison.cc b/src/abg-comparison.cc
index 71710338..1cfc0952 100644
--- a/src/abg-comparison.cc
+++ b/src/abg-comparison.cc
@@ -1380,9 +1380,6 @@  diff_context::maybe_apply_filters(diff_sptr diff)
   if (!diff)
     return;
 
-  if (get_allowed_category() == EVERYTHING_CATEGORY)
-    return;
-
   if (!diff->has_changes())
     return;