Skip to content

Commit

Permalink
Fix CleanupNetworkNamespace not properly detaching eBPF programs (#154
Browse files Browse the repository at this point in the history
)

CleanupNetworkNamespace: detach eBPF programs instead of resetting the probes
  • Loading branch information
YoannGh authored Oct 10, 2023
1 parent 41c28d3 commit 9541cb0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions netlink.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,12 @@ func (m *Manager) CleanupNetworkNamespace(nsID uint32) error {
continue
}

// disable probe
probe.Enabled = false

// stop the probe
errs = append(errs, probe.Stop())

// disable probe
probe.Enabled = false

// append probe to delete (biggest indexes first)
toDelete = append([]int{i}, toDelete...)
}
Expand Down

0 comments on commit 9541cb0

Please sign in to comment.