Skip to content

Commit

Permalink
Fix should trace ignored cgroups check (#301)
Browse files Browse the repository at this point in the history
  • Loading branch information
anjmao authored Jul 2, 2024
1 parent aa63b6c commit 5ec6628
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/ebpftracer/c/headers/common/filtering.h
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ statfunc u64 compute_scopes(program_data_t *p)

statfunc u64 should_trace(program_data_t *p)
{
if (bpf_map_lookup_elem(&ignored_cgroups_map, &p->task_info->context.cgroup_id) != NULL) {
if (bpf_map_lookup_elem(&ignored_cgroups_map, &p->event->context.task.cgroup_id) != NULL) {
return 0;
}

Expand Down
Binary file modified pkg/ebpftracer/tracer_arm64_bpfel.o
Binary file not shown.
2 changes: 1 addition & 1 deletion pkg/ebpftracer/tracer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ func TestTracer(t *testing.T) {
//{ID: events.NetPacketTCPBase},
{ID: events.SchedProcessExec},
//{ID: events.SecuritySocketConnect},
//{ID: events.SockSetState},
{ID: events.SockSetState},
//{ID: events.NetPacketDNSBase},
},
}
Expand Down
Binary file modified pkg/ebpftracer/tracer_x86_bpfel.o
Binary file not shown.

0 comments on commit 5ec6628

Please sign in to comment.