Handling MCI_CLOSE_DRIVER

When a driver receives an MCI_CLOSE_DRIVER command, it should close the object that is associated with the driver identifier received in dwDriverID. For a nonshared simple device, the object is the device. For a compound device, the object is an element.

If a device or element is being shared, then reception of an MCI_CLOSE_DRIVER message only means that the driver should no longer allow the caller access to the device or element. The device or element should be closed only after there are no longer any applications using it.