The equality check works because the proxy service caches proxies, and will always return the same wrapper. This fixes a leak and a situation that led to some asserts in XPConnect on shutdown. (Some listeners were proxy-wrapped JS objects.) r=jband.