mirror of https://github.com/tailscale/tailscale/
wgengine/wgcfg: always close io.Pipe
In DeviceConfig, we did not close r after calling FromUAPI. If FromUAPI returned early due to an error, then it might not have read all the data that IpcGetOperation wanted to write. As a result, IpcGetOperation could hang, as in #3220. We were also closing the wrong end of the pipe after IpcSetOperation in ReconfigDevice. To ensure that we get all available information to diagnose such a situation, include all errors anytime something goes wrong. This should fix the immediate crashing problem in #3220. We'll then need to figure out why IpcGetOperation was failing. Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com>pull/3140/head
parent
3fd5f4380f
commit
c467ed0b62
Loading…
Reference in New Issue