Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Konsole
Commits
b18d7c9d
Commit
b18d7c9d
authored
Nov 30, 2021
by
Tomaz Canabrava
Browse files
Use the correct variable on the inner loop
~Someone~ should fix the Qt model view framework to work with range based for.
parent
d2d2157f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/SSHManager/sshmanagermodel.cpp
View file @
b18d7c9d
...
...
@@ -120,7 +120,7 @@ bool SSHManagerModel::hasHost(const QString &host) const
// runs in O(N), should be ok for the amount of data peophe have.
for
(
int
i
=
0
,
end
=
invisibleRootItem
()
->
rowCount
();
i
<
end
;
i
++
)
{
QStandardItem
*
iChild
=
invisibleRootItem
()
->
child
(
i
);
for
(
int
e
=
0
,
end
=
iChild
->
rowCount
();
i
<
end
;
e
++
)
{
for
(
int
e
=
0
,
end
=
iChild
->
rowCount
();
e
<
end
;
e
++
)
{
QStandardItem
*
eChild
=
iChild
->
child
(
e
);
const
auto
data
=
eChild
->
data
(
SSHManagerModel
::
Roles
::
SSHRole
).
value
<
SSHConfigurationData
>
();
if
(
data
.
host
==
host
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment