mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 08:36:32 +01:00
Fix -Wunused-comparison in for() loop
Fixes potential issues when loading a session where state and IO port-count mismatches. Not sure if that can ever happen.
This commit is contained in:
parent
ee6e7e8a7e
commit
71f8c8ff38
1 changed files with 1 additions and 1 deletions
|
|
@ -615,7 +615,7 @@ IO::set_state (const XMLNode& node, int version)
|
||||||
*/
|
*/
|
||||||
PortSet::iterator i = _ports.begin();
|
PortSet::iterator i = _ports.begin();
|
||||||
XMLNodeConstIterator x = node.children().begin();
|
XMLNodeConstIterator x = node.children().begin();
|
||||||
for (; i != _ports.end(), x != node.children().end(); ++i, ++x) {
|
for (; i != _ports.end() && x != node.children().end(); ++i, ++x) {
|
||||||
if ((*x)->name() == "Port") {
|
if ((*x)->name() == "Port") {
|
||||||
(*x)->remove_property (X_("name"));
|
(*x)->remove_property (X_("name"));
|
||||||
(*x)->set_property (X_("name"), i->name());
|
(*x)->set_property (X_("name"), i->name());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue