diff options
author | Tomaz Canabrava <tcanabrava@kde.org> | 2018-09-14 16:49:18 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2018-09-15 15:51:26 -0700 |
commit | 7ab35f7858c8d840cf098de82f6b6265e4ec7b8b (patch) | |
tree | 00318256bd49ee960b9605de9973731272728f4a | |
parent | 00ef514da387b63311a6d02afc2e0cf9bdf9d05c (diff) | |
download | subsurface-7ab35f7858c8d840cf098de82f6b6265e4ec7b8b.tar.gz |
code cleanup: use ByteArray.size() instead of strlen
Removes a size_t vs int warning
Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | desktop-widgets/mainwindow.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/desktop-widgets/mainwindow.cpp b/desktop-widgets/mainwindow.cpp index a524d56cc..f5452b321 100644 --- a/desktop-widgets/mainwindow.cpp +++ b/desktop-widgets/mainwindow.cpp @@ -1761,7 +1761,7 @@ void MainWindow::importTxtFiles(const QStringList fileNames) for (int i = 0; i < fileNames.size(); ++i) { fileNamePtr = QFile::encodeName(fileNames.at(i)); csv = fileNamePtr.data(); - csv.replace(strlen(csv.data()) - 3, 3, "csv"); + csv.replace(csv.size() - 3, 3, "csv"); QFileInfo check_file(csv); if (check_file.exists() && check_file.isFile()) { |