Closed jakaplan closed 2 years ago
@amomchilov I basically tested this by just manually running the integration test over and over again. Before it was segfaulting roughly 20% of the time, after this change I've yet to see a segfault. That's not entirely satisfying, but seems strictly better than not addressing this issue.
It turns out occassionally
ServerTerminationIntegrationTest
'stestShutdownServer
would result in a segfault inside of the finalizer for the connection. I'm pretty sure the issue was that a retained count needs to be taken for the WeakConnection instance (what we don't want to do is add a retain count to the connection itself).