Here's a question that floated past some time ago:
In my code, I have multiple objects that want to talk to the
same handle (via DeviceIoControl).
Each time I create an object, I use DuplicateHandle
to increment the reference count on the handle.
That way, when each object calls CloseHandle,
only the last one actually closes the handle.