mirror of
https://github.com/libretro/scummvm.git
synced 2025-03-05 17:57:14 +00:00
Cleanup.
svn-id: r29476
This commit is contained in:
parent
2f062ff616
commit
a783c45d9e
@ -53,8 +53,7 @@ public:
|
||||
}
|
||||
|
||||
~Array() {
|
||||
if (_data)
|
||||
delete [] _data;
|
||||
delete [] _data;
|
||||
}
|
||||
|
||||
void push_back(const T& element) {
|
||||
@ -100,8 +99,7 @@ public:
|
||||
if (this == &array)
|
||||
return *this;
|
||||
|
||||
if (_data)
|
||||
delete [] _data;
|
||||
delete [] _data;
|
||||
_size = array._size;
|
||||
_capacity = _size + 32;
|
||||
_data = new T[_capacity];
|
||||
@ -115,10 +113,8 @@ public:
|
||||
}
|
||||
|
||||
void clear() {
|
||||
if (_data) {
|
||||
delete [] _data;
|
||||
_data = 0;
|
||||
}
|
||||
delete [] _data;
|
||||
_data = 0;
|
||||
_size = 0;
|
||||
_capacity = 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user