June 2003 - Posts

Quiz: Gotcha with Exceptions and HRESULTs
The C# code below, when executed, prints the following: 0x80004002 0x80004002 Who can figure out why the second line printed isn't 0x80004003 ? using System; using System.Runtime.InteropServices; public class Quiz { const int E_NOINTERFACE = unchecked((int)0x80004002); Read More...
CLR SPY and Customer Debug Probes: The Invalid IUnknown and Invalid VARIANT Probes
Whereas probes like Collected Delegate or Object Not Kept Alive catch coding mistakes in managed code, the Invalid IUnknown and Invalid VARIANT probes typically inform you when you're attempting to interoperate with a broken COM component. Either that, Read More...
Posted 11 June 03 04:27 by Adam Nathan | 6 Comments   
Filed under
CLR SPY and Customer Debug Probes: The Object Not Kept Alive and Buffer Overrun Probes (A Quiz)
The Object Not Kept Alive and Buffer Overrun probes are unlike any other CDPs, because they do not output any messages to report bugs in your code. Instead, they change general CLR behavior with the goal of forcing non-deterministic bugs that can be almost Read More...
TechEd Book Signing
I'll be doing a book signing (for .NET and COM: The Complete Interoperability Guide ) at the TechEd Mall tomorrow (Wed. 6/4) from 11:30-12:30 - immediately after the Interop presentation.  If you're at TechEd, please stop by! Read More...
Posted 03 June 03 03:05 by Adam Nathan | 4 Comments   
Filed under
CLR SPY and Customer Debug Probes: The Collected Delegate Probe
The most common mistake made when passing a delegate to unmanaged code (marshaled as a function pointer) is to allow the delegate to be garbage collected before unmanaged code is finished using it. This can happen because unmanaged code is invisible to Read More...
Posted 01 June 03 06:54 by Adam Nathan | 1 Comments   
Filed under
Page view tracker