Closed Awesome-Meng closed 1 year ago
Hi. I guess native image transfer will need the same treatment as capabilities.
Could you try the following patch to see if it works? fix_ds_native_transfer.patch
Hi, thank you for the advice. You're right, that fixed it. I just had to make one small change:
Twpp::Handle& handle = *static_cast<Twpp::Handle*>(data);
Instead, of Detail::Handle
.
Thanks, should be fixed now.
I use twpp as the base for my DS. For one specific App (QuickVision v6.04) periodically I will receive Memory Access Violation Exceptions leading to the program crashing.
The crash occurs within my custom definition of:
Specifically at the assignment operator call on
data
to the new size version:After a bit of digging, the likely culprit is the attempt to free
data
'sm_handle
. https://github.com/xricht17/twpp/blob/6b97c77967265c7dbc54ba2c7b1872439d4ab15d/twpp/memoryops.hpp#L420-L428Where in other applications
m_handle
isnull
, this App appears to providem_handle
as notnull
. Furthermore,GlobalMemFuncs<void>::doNotFreeHandle
which should be set the the same value is not equal at the time of the call tofree()
and therefore performs the invalid free operation.Is it possible that
doNotFreeHandle
is not correctly set? I performed some logged and found calls toDoNotFreeHandle::~DoNotFreeHandle()
happened prior to the call tofree()
. However, I could be wrong and this could be entirely the App's fault for incorrectly setting the data. Any assistance in this would be greatly appreciated. I'm running on Windows 10, building with Clang++ (version 15.0.6).