CloseHandle() not closing.... [modified]
-
I have created an application(run on win2k) where i communicate with a pci device. Within this application i establish communication by creating a handle to the device. After I've completed the tasks i've set out to do in the application i do:
CloseHandle(hdevice);
i know that: "CloseHandle invalidates the specified object handle,..." to debug i do:if(!CloseHandle(hdevice)) AfxMessageBox(_T("DEBUG: Handle ::hndlPciAlt:: not closed!"));
but i never see this message..... however, from debugging it seems as thought the application was not successful at closing the handle to the device(even when i exit my application). (unless something else is happening...) the reason i say this is when i use a separate test application provided by the manufacturer to reload and reset the FPGA on the device the registers are not being reset. if anyone has any insight on this issue, please advice... thanks in advance, -- modified at 8:58 Friday 3rd November, 2006Kitty5