[ruby-core:121653] [Ruby Bug#21261] Backport fix for crash in TCPSocket.open(..., nil)