mirror of
https://github.com/coder/coder.git
synced 2026-09-22 13:10:21 +08:00
fixes https://github.com/coder/internal/issues/221 Fixes an issue where two goroutines were sharing the `err` variable, leading to a data race where we'd fail to process the error and then nil-pointer panic. I ended up refactoring reconnecting PTY stuff into the `reconnectingpty` package, instead of having it on the agent. That `createTailnet` routine had waaay too many deeply nested goroutines, which is I'm sure a big contributor to the bug appearing in the first place.