diff options
author | George Hazan <george.hazan@gmail.com> | 2012-07-29 17:44:31 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-07-29 17:44:31 +0000 |
commit | 6eb6a545a869d91578dfa31844783f1f062129d0 (patch) | |
tree | 4765a5a4e1b32ef3d851ec3a11766b5d73c30624 /include/m_system_cpp.h | |
parent | c14ed6c75c2c6dfcdaf94597cfb59db42749b140 (diff) |
fix for the double object deletion in MSN
git-svn-id: http://svn.miranda-ng.org/main/trunk@1242 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'include/m_system_cpp.h')
-rw-r--r-- | include/m_system_cpp.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/m_system_cpp.h b/include/m_system_cpp.h index 4c8656b4e2..2e71c4dcff 100644 --- a/include/m_system_cpp.h +++ b/include/m_system_cpp.h @@ -195,8 +195,9 @@ template<class T> struct OBJLIST : public LIST<T> __inline int remove(T* p)
{
- if (List_RemovePtr((SortedList*)this, p) != -1) {
- delete p;
+ int i = getIndex( p );
+ if ( i != -1 ) {
+ remove(i);
return 1;
}
return 0;
|