summaryrefslogtreecommitdiffstats
path: root/Source/cmMachO.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmMachO.cxx')
-rw-r--r--Source/cmMachO.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/Source/cmMachO.cxx b/Source/cmMachO.cxx
index 8002175..7294c1c 100644
--- a/Source/cmMachO.cxx
+++ b/Source/cmMachO.cxx
@@ -251,8 +251,7 @@ cmMachOInternal::cmMachOInternal(const char* fname)
}
// parse each Mach-O file
- for (size_t i = 0; i < this->FatArchs.size(); i++) {
- const fat_arch& arch = this->FatArchs[i];
+ for (const auto& arch : this->FatArchs) {
if (!this->read_mach_o(OSSwapBigToHostInt32(arch.offset))) {
return;
}
@@ -265,8 +264,8 @@ cmMachOInternal::cmMachOInternal(const char* fname)
cmMachOInternal::~cmMachOInternal()
{
- for (size_t i = 0; i < this->MachOList.size(); i++) {
- delete this->MachOList[i];
+ for (auto& i : this->MachOList) {
+ delete i;
}
}