diff options
| author | 2020-12-21 20:50:51 -0800 | |
|---|---|---|
| committer | 2021-06-22 01:21:04 +0200 | |
| commit | d2b9cc8bef501c5a8dc4dc7206d302585906546a (patch) | |
| tree | a662a5527c4b0e5f6249a2ee9b7d29e6b5e40643 /src/Array.cpp | |
| parent | 8c7e258e80c632c2d1d1eaa93cef8358a898045b (diff) | |
| download | libplist-d2b9cc8bef501c5a8dc4dc7206d302585906546a.tar.gz libplist-d2b9cc8bef501c5a8dc4dc7206d302585906546a.tar.bz2 | |
[clang-tidy] cpp: Use correct type for loop variable
Found with bugprone-too-small-loop-variable
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Diffstat (limited to 'src/Array.cpp')
| -rw-r--r-- | src/Array.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/Array.cpp b/src/Array.cpp index 8838e5b..65ffaa7 100644 --- a/src/Array.cpp +++ b/src/Array.cpp | |||
| @@ -61,8 +61,7 @@ Array::Array(const PList::Array& a) | |||
| 61 | Array& Array::operator=(const PList::Array& a) | 61 | Array& Array::operator=(const PList::Array& a) |
| 62 | { | 62 | { |
| 63 | plist_free(_node); | 63 | plist_free(_node); |
| 64 | for (unsigned int it = 0; it < _array.size(); it++) | 64 | for (size_t it = 0; it < _array.size(); it++) { |
| 65 | { | ||
| 66 | delete _array.at(it); | 65 | delete _array.at(it); |
| 67 | } | 66 | } |
| 68 | _array.clear(); | 67 | _array.clear(); |
| @@ -73,8 +72,7 @@ Array& Array::operator=(const PList::Array& a) | |||
| 73 | 72 | ||
| 74 | Array::~Array() | 73 | Array::~Array() |
| 75 | { | 74 | { |
| 76 | for (unsigned int it = 0; it < _array.size(); it++) | 75 | for (size_t it = 0; it < _array.size(); it++) { |
| 77 | { | ||
| 78 | delete (_array.at(it)); | 76 | delete (_array.at(it)); |
| 79 | } | 77 | } |
| 80 | _array.clear(); | 78 | _array.clear(); |
