Add a by-address equality short-circuit to condition comparison
[lttng-tools.git] / src / common / condition.c
index 9a9e9babdfa19a7145f22508bc81b863f1406078..6cebeb03f7bb9d35e651a9a110bb36f087cfd1fe 100644 (file)
@@ -104,6 +104,11 @@ bool lttng_condition_is_equal(const struct lttng_condition *a,
                goto end;
        }
 
+       if (a == b) {
+               is_equal = true;
+               goto end;
+       }
+
        is_equal = a->equal ? a->equal(a, b) : true;
 end:
        return is_equal;
This page took 0.023685 seconds and 5 git commands to generate.