You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
int main()
{
dds::domain::DomainParticipant dp1(dds::core::null);
{
dds::domain::DomainParticipant dp2(0); //Creates a domain participant on domain 0
dp1 = dp2; //Copies reference to dp2 into dp1, both references now point to the same class instance
}
std::cin.get();
}
However as the program exits, after a button is pressed, a break point is hit on line 676 of memory.
// CLASS TEMPLATE _Ref_count
template <class _Ty>
class _Ref_count : public _Ref_count_base { // handle reference counting for pointer without deleter
public:
explicit _Ref_count(_Ty* _Px) : _Ref_count_base(), _Ptr(_Px) {}
private:
virtual void _Destroy() noexcept override { // destroy managed resource
delete _Ptr; <---- This Line
}
virtual void _Delete_this() noexcept override { // destroy self
delete this;
}
_Ty* _Ptr;
};
The exception "A heap has been corrupted" is thrown when trying to continue execution.
I built from source using the latest CYGWin on windows 10.
The text was updated successfully, but these errors were encountered:
I am running this in a test program:
However as the program exits, after a button is pressed, a break point is hit on line 676 of memory.
The exception "A heap has been corrupted" is thrown when trying to continue execution.
I built from source using the latest CYGWin on windows 10.
The text was updated successfully, but these errors were encountered: