Install & Compatibility
Where this runs
No compatibility data collected yet for this library.
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
fastping
✓ github.com/servak/go-fastping
Ping an IP address and handle responses.
package main
import (
"fmt"
"github.com/servak/go-fastping"
"net"
"time"
)
func main() {
p := fastping.NewPinger()
ra, _ := net.ResolveIPAddr("ip4:icmp", "127.0.0.1")
p.AddIPAddr(ra)
p.OnRecv = func(addr *net.IPAddr, rtt time.Duration) {
fmt.Printf("IP %s received, RTT %v\n", addr, rtt)
}
p.Run()
}
Debug
Known issues
No known issues recorded.
Upgrade
Version history
0.0.0-20160802140958-5718d12e20a0latest on pkg.go.dev
Audit
Dependencies
No dependency data recorded yet.