Skip to content

Commit b0030e8

Browse files
committed
Removed unused code
1 parent 75bab0b commit b0030e8

File tree

2 files changed

+1
-14
lines changed

2 files changed

+1
-14
lines changed

pkg/network/tracer/connection/ebpf_tracer.go

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,6 @@ const (
4646
connTracerModuleName = "network_tracer__ebpf"
4747
)
4848

49-
var (
50-
// ErrEbpfTracerNotSupported is the error returned when the eBPF tracer is not supported
51-
ErrEbpfTracerNotSupported = fmt.Errorf("ebpf not supported on this platform")
52-
)
53-
5449
//nolint:revive // TODO(NET) Fix revive linter
5550
var EbpfTracerTelemetry = struct {
5651
connections telemetry.Gauge

pkg/network/tracer/connection/ebpfless_tracer.go

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
package connection
99

1010
import (
11-
"errors"
1211
"fmt"
1312
"io"
1413
"sync"
@@ -40,9 +39,6 @@ const (
4039
)
4140

4241
var (
43-
// ErrEbpflessNotSupported is the error returned when the ebpfless tracer is not supported
44-
ErrEbpflessNotSupported = errors.New("ebpf-less tracer not supported")
45-
4642
ebpfLessTracerTelemetry = struct {
4743
skippedPackets telemetry.Counter
4844
}{
@@ -72,11 +68,7 @@ type ebpfLessTracer struct {
7268
ns netns.NsHandle
7369
}
7470

75-
// NewEbpfLessTracer creates a new ebpfLessTracer instance
76-
func NewEbpfLessTracer(cfg *config.Config) (Tracer, error) {
77-
return newEbpfLessTracer(cfg)
78-
}
79-
71+
// newEbpfLessTracer creates a new ebpfLessTracer instance
8072
func newEbpfLessTracer(cfg *config.Config) (*ebpfLessTracer, error) {
8173
packetSrc, err := filter.NewAFPacketSource(
8274
8<<20, // 8 MB total space

0 commit comments

Comments
 (0)