Fix exception in __ComObject finalizer during shutdown

* keep a reference to a __ComObject's proxy so it doesn't get garbage
collected
* don't create __ComObjects unnecessarily
* Fix for bug 24974

Change-Id: I7f6e6c544497bd117b9d156bdd0555932aa057a3