I haven't tried your patch, but good work!

This is/was a major pain for those of us using Ruby in the corporate
environment.

cheers!!