mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-08-20 21:33:57 -07:00
This commit is contained in:
parent
b540181990
commit
fbf74d3baa
5 changed files with 52 additions and 11 deletions
|
@ -38,6 +38,18 @@ type nativeTap struct {
|
|||
multicastGroupHandlersLock sync.Mutex
|
||||
}
|
||||
|
||||
var _ Tap = &nativeTap{}
|
||||
|
||||
// Type returns a human-readable description of this tap implementation
|
||||
func (t *nativeTap) Type() string {
|
||||
return "native"
|
||||
}
|
||||
|
||||
// Error gets this tap device's error status
|
||||
func (t *nativeTap) Error() (int, string) {
|
||||
return 0, ""
|
||||
}
|
||||
|
||||
// SetEnabled sets this tap's enabled state
|
||||
func (t *nativeTap) SetEnabled(enabled bool) {
|
||||
if enabled && atomic.SwapUint32(&t.enabled, 1) == 0 {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue