Coverity COPY_INSTEAD_OF_MOVE issues
[email protected] Wed, 24 Dec 2025 10:56:43 -0500
| Newsgroups | gmane.comp.kde.devel.konsole |
|---|---|
| Message-ID | <[email protected]> |
There are a lot of these that coverity flags. Anyone have an =
opinion on if these are worthwhile to research and change?
ProfileReader.cpp =09
CID 637585: (#1 of 1): Variable copied when it could be moved =
(COPY_INSTEAD_OF_MOVE)
copy_constructor_call: profile is passed-by-value as parameter to =
readProperties, when it could be moved instead.[show details]
Use std::move(profile) instead of profile.
106 readProperties(config, profile);
SessionManager.cpp =09
CID 637584: (#1 of 1): Variable copied when it could be moved =
(COPY_INSTEAD_OF_MOVE)
copy_constructor_call: ptr is passed-by-value as parameter to =
createSession, when it could be moved instead.[show details]
Use std::move(ptr) instead of ptr.
377 Session *session =3D createSession(ptr);
Application.cpp =09
CID 637583: (#1 of 1): Variable copied when it could be moved =
(COPY_INSTEAD_OF_MOVE)
copy_constructor_call: baseProfile is passed-by-value as parameter to =
processProfileChangeArgs, when it could be moved instead.[show details]
194 Use std::move(baseProfile) instead of baseProfile.
About 25 more=E2=80=A6 thanks
Kurt=