Capture socket and reader ownership before deferred teardown

When websocket teardown runs asynchronously while reconnect is allowed, capture both the old socket and its reader task before releasing ownership. A socket identity guard alone does not protect a replacement reader if teardown later looks up a mutable current-reader field. An absent old reader must mean no reader to cancel, rather than falling back to the current one. Detach references synchronously, then close only captured resources and ignore stale reader failures. This protects local ownership; provider cleanup and arbitrary asynchronous event-handler behavior still require separate verification.

Applies when: websocket clients defer shutdown while a replacement connection can start. Keywords: websocket reconnect reader task ownership cleanup teardown stale asyncio cancellation