From 288153b53b3130733af5f4cb66b16ad30125e248 Mon Sep 17 00:00:00 2001 From: Vihas Makwana Date: Tue, 17 Dec 2024 23:57:13 +0530 Subject: [PATCH] lint --- metric/system/process/process_windows.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/metric/system/process/process_windows.go b/metric/system/process/process_windows.go index 238d73bce..b6af0563e 100644 --- a/metric/system/process/process_windows.go +++ b/metric/system/process/process_windows.go @@ -27,7 +27,9 @@ import ( "unsafe" xsyswindows "golang.org/x/sys/windows" + "golang.org/x/sys/windows/registry" + "github.com/elastic/elastic-agent-libs/logp" "github.com/elastic/elastic-agent-libs/opt" "github.com/elastic/elastic-agent-system-metrics/metric/system/resolve" gowindows "github.com/elastic/go-windows" @@ -467,7 +469,7 @@ func fillIdleProcess(state ProcState) (ProcState, error) { return state, nil } -func shouldIgnore(pid int) (bool, err) { +func shouldIgnore(pid int) bool { // shouldIgnore checks if we should ignore the pid, to avoid elevated permissions // LSASS.exe is a process which has no useful cmdline arguments, we should ignore acessing such process to avoid triggering Windows ASR rules