From 9552d964fe1b0d1a85bd0ccd5fbb9f9a59ff11f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Mon, 18 May 2020 16:02:48 -0300 Subject: [PATCH] QGCTileCacheWorker: Fix deprecated QString::sprintf MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- src/QtLocationPlugin/QGCTileCacheWorker.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/QtLocationPlugin/QGCTileCacheWorker.cpp b/src/QtLocationPlugin/QGCTileCacheWorker.cpp index f18626ac7..37db5755d 100644 --- a/src/QtLocationPlugin/QGCTileCacheWorker.cpp +++ b/src/QtLocationPlugin/QGCTileCacheWorker.cpp @@ -736,8 +736,7 @@ QGCCacheWorker::_importSets(QGCMapTask* mtask) int testCount = 0; //-- Set with this name already exists. Make name unique. while (true) { - QString testName; - testName.sprintf("%s %02d", name.toLatin1().data(), ++testCount); + auto testName = QString::asprintf("%s %02d", name.toLatin1().data(), ++testCount); if(!_findTileSetID(testName, insertSetID) || testCount > 99) { name = testName; break; -- 2.22.0