diff options
author | Johannes Schickel | 2007-11-11 11:39:59 +0000 |
---|---|---|
committer | Johannes Schickel | 2007-11-11 11:39:59 +0000 |
commit | a783c45d9e6064bf7d9e884fbf6857f2de1b7fc5 (patch) | |
tree | 355d3eea868426de66fe20e8a01bf1797413251d | |
parent | 2f062ff61678934aef2a1252bbd08ed0c191b170 (diff) | |
download | scummvm-rg350-a783c45d9e6064bf7d9e884fbf6857f2de1b7fc5.tar.gz scummvm-rg350-a783c45d9e6064bf7d9e884fbf6857f2de1b7fc5.tar.bz2 scummvm-rg350-a783c45d9e6064bf7d9e884fbf6857f2de1b7fc5.zip |
Cleanup.
svn-id: r29476
-rw-r--r-- | common/array.h | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/common/array.h b/common/array.h index af9ec811da..8d7ccb6a60 100644 --- a/common/array.h +++ b/common/array.h @@ -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; } |