mirror of https://github.com/shirou/gopsutil
[net][linux]: remove unused files. go1.11 is not supported now.
parent
e9591b5b01
commit
5cd488ff30
@ -1,12 +0,0 @@
|
||||
// SPDX-License-Identifier: BSD-3-Clause
|
||||
//go:build !go1.16
|
||||
|
||||
package net
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
func readDir(f *os.File, max int) ([]os.FileInfo, error) {
|
||||
return f.Readdir(max)
|
||||
}
|
@ -1,12 +0,0 @@
|
||||
// SPDX-License-Identifier: BSD-3-Clause
|
||||
//go:build go1.16
|
||||
|
||||
package net
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
func readDir(f *os.File, max int) ([]os.DirEntry, error) {
|
||||
return f.ReadDir(max)
|
||||
}
|
@ -1,20 +0,0 @@
|
||||
// SPDX-License-Identifier: BSD-3-Clause
|
||||
//go:build linux
|
||||
|
||||
package net
|
||||
|
||||
import "testing"
|
||||
|
||||
func BenchmarkGetConnectionsInet(b *testing.B) {
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
Connections("inet")
|
||||
}
|
||||
}
|
||||
|
||||
func BenchmarkGetConnectionsAll(b *testing.B) {
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
Connections("all")
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue