Skip to content

Commit

Permalink
Merge pull request #1795 from shirou/feat/fix_revice_lint_error_on_any
Browse files Browse the repository at this point in the history
[windows]: fix lint error about use-any
  • Loading branch information
shirou authored Feb 20, 2025
2 parents 22889d3 + 8897eba commit 23ceac3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/common/common_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ func ProcessorQueueLengthCounter() (*Win32PerformanceCounter, error) {
}

// WMIQueryWithContext - wraps wmi.Query with a timed-out context to avoid hanging
func WMIQueryWithContext(ctx context.Context, query string, dst interface{}, connectServerArgs ...interface{}) error {
func WMIQueryWithContext(ctx context.Context, query string, dst any, connectServerArgs ...any) error {
if _, ok := ctx.Deadline(); !ok {
ctxTimeout, cancel := context.WithTimeout(ctx, Timeout)
defer cancel()
Expand Down
2 changes: 1 addition & 1 deletion net/net_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ func getTableUintptr(family uint32, buf []byte) uintptr {
return p
}

func getTableInfo(filename string, table interface{}) (index, step, length int) {
func getTableInfo(filename string, table any) (index, step, length int) {
switch filename {
case kindTCP4.filename:
index = int(unsafe.Sizeof(table.(pmibTCPTableOwnerPidAll).DwNumEntries))
Expand Down

0 comments on commit 23ceac3

Please sign in to comment.