Skip to content

Commit 23ceac3

Browse files
authored
Merge pull request #1795 from shirou/feat/fix_revice_lint_error_on_any
[windows]: fix lint error about use-any
2 parents 22889d3 + 8897eba commit 23ceac3

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

internal/common/common_windows.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ func ProcessorQueueLengthCounter() (*Win32PerformanceCounter, error) {
197197
}
198198

199199
// WMIQueryWithContext - wraps wmi.Query with a timed-out context to avoid hanging
200-
func WMIQueryWithContext(ctx context.Context, query string, dst interface{}, connectServerArgs ...interface{}) error {
200+
func WMIQueryWithContext(ctx context.Context, query string, dst any, connectServerArgs ...any) error {
201201
if _, ok := ctx.Deadline(); !ok {
202202
ctxTimeout, cancel := context.WithTimeout(ctx, Timeout)
203203
defer cancel()

net/net_windows.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ func getTableUintptr(family uint32, buf []byte) uintptr {
328328
return p
329329
}
330330

331-
func getTableInfo(filename string, table interface{}) (index, step, length int) {
331+
func getTableInfo(filename string, table any) (index, step, length int) {
332332
switch filename {
333333
case kindTCP4.filename:
334334
index = int(unsafe.Sizeof(table.(pmibTCPTableOwnerPidAll).DwNumEntries))

0 commit comments

Comments
 (0)