Fixed a marshaling exception with a GC'd delegate being called still