We are working a new project in c++ where we are communicating to a DLL with an Explicit connection. We are creating the memory in the host calling device and are passing a shared pointer to the DLL to allow it to write the data into the host memory. As we monitor the data coming back into the watch window we see the data and it looks good at first, then for some inexplicable reason the data gets trashed. So it did look proper for a moment and then it became unstable. The DLL only transfers once and that is all we asked from the device. Every thing says that the issue is on the host side since the data looked proper before it fell apart. We were working with standard pointers at first and swapped this for a shared pointer. We were worried that the pointer may gave been corrupted, but this seems highly unlikely since we did receive the data initially I'm looking for a little insight into what may be occurring or maybe some 3rd party tools that may assist with the issue. We are working in Visual Studio latest addition. Best Regards
We have created another test Dll project with a slightly modified collection system. Testing this we have no issues, but the return is dummy data. The real system connects to an industrial sensor for input and that seem to be working fine and to re-iterate the data came in initially seemingly well at first. It smelled like the memory was trashed by a bad pointer, but we are only collecting from the DLL one time. Is there a way that we could protect the memory and when that memory is being changed to catch this in an exception block somehow. Software tools or maybe some code ideas. Best Regards