aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/trace_events_filter.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c
index 936c621bbf46..1557148be34b 100644
--- a/kernel/trace/trace_events_filter.c
+++ b/kernel/trace/trace_events_filter.c
@@ -1029,6 +1029,8 @@ static int replace_preds(struct event_subsystem *system,
1029 1029
1030 if (elt->op == OP_AND || elt->op == OP_OR) { 1030 if (elt->op == OP_AND || elt->op == OP_OR) {
1031 pred = create_logical_pred(elt->op); 1031 pred = create_logical_pred(elt->op);
1032 if (!pred)
1033 return -ENOMEM;
1032 if (call) { 1034 if (call) {
1033 err = filter_add_pred(ps, call, pred); 1035 err = filter_add_pred(ps, call, pred);
1034 filter_free_pred(pred); 1036 filter_free_pred(pred);
@@ -1048,6 +1050,8 @@ static int replace_preds(struct event_subsystem *system,
1048 } 1050 }
1049 1051
1050 pred = create_pred(elt->op, operand1, operand2); 1052 pred = create_pred(elt->op, operand1, operand2);
1053 if (!pred)
1054 return -ENOMEM;
1051 if (call) { 1055 if (call) {
1052 err = filter_add_pred(ps, call, pred); 1056 err = filter_add_pred(ps, call, pred);
1053 filter_free_pred(pred); 1057 filter_free_pred(pred);