Skip to content

Commit

Permalink
Fix compilation against Qt 5
Browse files Browse the repository at this point in the history
  • Loading branch information
Martchus committed Apr 9, 2024
1 parent 0bb7120 commit 96f26e8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion syncthingmodel/syncthingfilemodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ QString SyncthingFileModel::path(const QModelIndex &index) const
auto size = QString::size_type();
parts.reserve(reinterpret_cast<SyncthingItem *>(index.internalPointer())->level + 1);
for (auto i = index; i.isValid(); i = i.parent()) {
size += parts.emplace_back(reinterpret_cast<SyncthingItem *>(i.internalPointer())->name).size();
parts.append(reinterpret_cast<SyncthingItem *>(i.internalPointer())->name);
size += parts.back().size();
}
res.reserve(size + parts.size());
for (auto i = parts.rbegin(), end = parts.rend(); i != end; ++i) {
Expand Down

0 comments on commit 96f26e8

Please sign in to comment.