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
您好,出于某种目的,我需要new一个CSelection的对象,就像这样:CSelection* sel = new CSelection(selection),调用的拷贝构造函数。然而在程序的最后我有delete这个指针,但是用valgrind检测的时候还是检测出了内存泄露。释放CSelection对象的时候是直接delete还是调用release()函数呢?还是说这是个潜在的内存泄露问题?英文不好所以就用中文了,望解答,谢谢!
The text was updated successfully, but these errors were encountered:
您好,出于某种目的,我需要new一个CSelection的对象,就像这样:CSelection* sel = new CSelection(selection),调用的拷贝构造函数。然而在程序的最后我有delete这个指针,但是用valgrind检测的时候还是检测出了内存泄露。释放CSelection对象的时候是直接delete还是调用release()函数呢?还是说这是个潜在的内存泄露问题?英文不好所以就用中文了,望解答,谢谢!
The text was updated successfully, but these errors were encountered: