Absolutely, let me clarify: The GC is necessarily unaware (or at least has limited awareness) of non-memory resource limits. These typically must be managed explicitly, regardless of GC behavior. I think a common example from Ruby is the use of constructs such as:

```
loop { IO.popen("echo hi") { |f| f.read } }
```

Instead of

```
loop { IO.popen("echo hi").read }
```

The former can clean up state after the yield, whereas the GC is unequipped to handle the external resources in the latter case. I'm only suggesting we face a similar issue here, where the mysql C library bits are the externalized resources. Compounding this, the externalized resources are shared. It's an otherwise correct cleanup in one GC instance which breaks another.

To be clear, the gc interaction is broken right now, any time a fork occurs. This is a possible fix (which I've amended a bit, I think this suggestion may be more palatable: https://github.com/brianmario/mysql2/pull/463#issuecomment-31772408 )