diff options
author | Josh Bleecher Snyder <josh@tailscale.com> | 2021-01-15 13:59:55 -0800 |
---|---|---|
committer | Josh Bleecher Snyder <josh@tailscale.com> | 2021-01-25 08:47:48 -0800 |
commit | db3fa1409cae2113df73f1641d9fb1830fbcc696 (patch) | |
tree | 91f6767be61bb1dbb18ab3800d1a0efe45fbe4e5 /device/uapi.go | |
parent | 675aae24232750e5a41c0a10bb1195fa4bb63d42 (diff) |
device: remove dead code
If device.NewPeer returns a nil error,
then the returned peer is always non-nil.
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com>
Diffstat (limited to 'device/uapi.go')
-rw-r--r-- | device/uapi.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/device/uapi.go b/device/uapi.go index dbb60b6..4436e72 100644 --- a/device/uapi.go +++ b/device/uapi.go @@ -247,12 +247,7 @@ func (device *Device) IpcSetOperation(r io.Reader) error { logError.Println("Failed to create new peer:", err) return &IPCError{ipc.IpcErrorInvalid} } - if peer == nil { - dummy = true - peer = &Peer{} - } else { - logDebug.Println(peer, "- UAPI: Created") - } + logDebug.Println(peer, "- UAPI: Created") } case "update_only": |