This example shows what a call to UnRegisterSource looks like. Refer to ISystemDebugEventInstall Example (Visual C++) to see the constant declarations and object creation code, as well as to see this code in a form you can run with minor modifications.
// Unregister the component.
void SampleUnRegisterSource()
{
pESI->UnRegisterSource( SAMPLE_SOURCE_GUID );
}