From 2e35e09c963c79a5620f660104187e501eefe30d Mon Sep 17 00:00:00 2001 From: Eduard Braun Date: Sat, 10 Oct 2015 22:35:11 +0200 Subject: [PATCH] Songinfo/lyrics: Fix index error in "UltimateLyricsProvider::Extract" (second argument to "QString,mid()" is number of characters, not end index) --- src/songinfo/ultimatelyricsprovider.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/songinfo/ultimatelyricsprovider.cpp b/src/songinfo/ultimatelyricsprovider.cpp index 586e5d239..e3a51b7eb 100644 --- a/src/songinfo/ultimatelyricsprovider.cpp +++ b/src/songinfo/ultimatelyricsprovider.cpp @@ -223,7 +223,7 @@ QString UltimateLyricsProvider::Extract(const QString& source, int end_idx = source.indexOf(end, begin_idx); if (end_idx == -1) return QString(); - return source.mid(begin_idx, end_idx - begin_idx - 1); + return source.mid(begin_idx, end_idx - begin_idx); } void UltimateLyricsProvider::ApplyExcludeRule(const Rule& rule,