[graphics/digikam] core/libs/metadataengine/dmetadata: cppcheck++: invalid container usage

Gilles Caulier <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 997ab5ae1ea32d0612f9b1237b146f150f71bece by Gilles Caulier.
Committed on 09/08/2026 at 21:48.
Pushed by cgilles into branch 'master'.

cppcheck++: invalid container usage

M  +4    -4    core/libs/metadataengine/dmetadata/dmetadata_imagemagick.cpp

https://invent.kde.org/graphics/digikam/-/commit/997ab5ae1ea32d0612f9b1237b146f150f71bece

diff --git a/core/libs/metadataengine/dmetadata/dmetadata_imagemagick.cpp b/core/libs/metadataengine/dmetadata/dmetadata_imagemagick.cpp
index 5d8202d2e2..14050784c6 100644
--- a/core/libs/metadataengine/dmetadata/dmetadata_imagemagick.cpp
+++ b/core/libs/metadataengine/dmetadata/dmetadata_imagemagick.cpp
@@ -201,10 +201,10 @@ bool DMetadata::loadUsingImageMagick(const QString& filePath)
         char** identargv    = new char*[identargc];          // Container to store arguments.
         identargv[0]        = const_cast<char*>("identify"); // String content is not important but must be present.
         identargv[1]        = const_cast<char*>("-format");  // We will pass percent escape options.
-        QByteArray ba       = filters.toLatin1();
-        identargv[2]        = ba.data();                     // Percent escape format description.
-        ba                  = filePath.toLatin1();
-        identargv[3]        = ba.data();                     // The file path to parse (even if this also passed through IM::ImageInfo container).
+        QByteArray ba1      = filters.toLatin1();
+        identargv[2]        = ba1.data();                    // Percent escape format description.
+        QByteArray ba2      = filePath.toLatin1();
+        identargv[3]        = ba2.data();                    // The file path to parse (even if this also passed through IM::ImageInfo container).
 
         // Call ImageMagick core identification.
         // This is a fast IM C API call, not the IM CLI tool process.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.