| Esteban (19) | |||
|
Hey, I wrote a program using VS2010 communicating with 2 USB devices and processing the data they send. The program is working, but for some reason it sometimes crash randomly, throwing a USB Read timeout exception. The USB devices are perfectly working and the test project I wrote using their API is never crashing, so I think it has nothing to do with a USB timeout. I tried to investigate raise conditions, so I serialized all my threads access to the USB with mutexes, but it didn't solve the problem. I also tried to investigate memory leaks with CRTDBG functions and corrected a few leaks, but it also didn't solve the problem, and I don't see any leak left. I'm now trying to investigate heap/stack corruption, but I'm quite a beginner in that. I'm using Application Verifier, and when I activate the "heaps" tests the visual studio debugger is breaking on an access violation. Surprisingly it is breaking in an header file which is not even executed by my program, (written for other usb devices) and I don't understand why it is breaking there. If I set a breakpoint at this place and run the program step by step the breakpoint never get hit so I guess it is not relevant. The detailed error is:
I don't post any code at the moment since the program is really big and I don't know where the problem comes from. I would really appreciate any help on this, I've been spending a lot of time to find this bug but unsuccessfully at the moment :/ | |||
|
Last edited on
|
|||