]> git.ipfire.org Git - thirdparty/wireguard-go.git/commit
device: add nil check before convert typed error back
authorWenxuan Zhao <viz@linux.com>
Sat, 18 Apr 2020 14:27:39 +0000 (07:27 -0700)
committerDavid Crawshaw <crawshaw@tailscale.com>
Fri, 1 May 2020 14:49:10 +0000 (00:49 +1000)
commit75a41b24ad2937169a6b4d0a2909dac1ffff726f
tree769e1a22eae04d8b0f08d864d5bba80b0473ebc3
parenta4657f996d98378c06cc7da4d2c69539c19dae32
device: add nil check before convert typed error back

Since errors.As(err, target) returns false when err is nil,
which cause status set to 1 when no error occurs for Ipc{Get,Set}Operation.

Signed-off-by: Wenxuan Zhao <viz@linux.com>
device/uapi.go