mirror of
https://github.com/weaveworks/scope.git
synced 2026-03-03 18:20:27 +00:00
Remove redundant arg from newEbpfTracker
This commit is contained in:
@@ -42,7 +42,7 @@ func newConnectionTracker(conf connectionTrackerConfig) connectionTracker {
|
||||
}
|
||||
}
|
||||
// When ebpf will be active by default, check if it starts correctly otherwise fallback to flowWalk
|
||||
et, err := newEbpfTracker(conf.UseEbpfConn)
|
||||
et, err := newEbpfTracker()
|
||||
if err != nil {
|
||||
// TODO: fallback to flowWalker, when ebpf is enabled by default
|
||||
log.Errorf("Error setting up the ebpfTracker, connections will not be reported: %s", err)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package endpoint
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"regexp"
|
||||
"strconv"
|
||||
@@ -77,11 +76,7 @@ func isKernelSupported() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func newEbpfTracker(useEbpfConn bool) (eventTracker, error) {
|
||||
if !useEbpfConn {
|
||||
return nil, errors.New("ebpf tracker not enabled")
|
||||
}
|
||||
|
||||
func newEbpfTracker() (eventTracker, error) {
|
||||
if err := isKernelSupported(); err != nil {
|
||||
return nil, fmt.Errorf("kernel not supported: %v", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user