summaryrefslogtreecommitdiffstats
path: root/src/Array.cpp
diff options
context:
space:
mode:
authorGravatar Jonathan Beck2009-10-28 17:57:52 +0100
committerGravatar Jonathan Beck2009-10-28 17:57:52 +0100
commit1bc333972bb5d5b45ba8908f1b12015300d88711 (patch)
treed061424c0ba0390259ae092df68c9c7462e16315 /src/Array.cpp
parenta129688a888968286a30eeba7833629225c59fa0 (diff)
downloadlibplist-1bc333972bb5d5b45ba8908f1b12015300d88711.tar.gz
libplist-1bc333972bb5d5b45ba8908f1b12015300d88711.tar.bz2
Fix build for MSVC9.
Diffstat (limited to 'src/Array.cpp')
-rw-r--r--src/Array.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Array.cpp b/src/Array.cpp
index 7c8272c..dbb1239 100644
--- a/src/Array.cpp
+++ b/src/Array.cpp
@@ -58,7 +58,7 @@ Array::Array(PList::Array& a) : Structure()
Array& Array::operator=(PList::Array& a)
{
plist_free(_node);
- for (int it = 0; it < _array.size(); it++)
+ for (unsigned int it = 0; it < _array.size(); it++)
{
delete _array.at(it);
}
@@ -72,11 +72,12 @@ Array& Array::operator=(PList::Array& a)
plist_t subnode = plist_array_get_item(_node, i);
_array.push_back( Utils::FromPlist(subnode, this) );
}
+ return *this;
}
Array::~Array()
{
- for (int it = 0; it < _array.size(); it++)
+ for (unsigned int it = 0; it < _array.size(); it++)
{
delete (_array.at(it));
}