Fix issue where if a client disconnects in the middle of a long running IPC method call, the server will segfault when the method eventually returns.
This issue was reported tdb3 in https://github.com/bitcoin/bitcoin/pull/31003#pullrequestreview-2349619672 with a stack trace showing where the crash happens in the PassField mp.Context overload while calling request_threads.erase.