From 5f6bbb20e775e86b9aba3deb86751299dac3dd65 Mon Sep 17 00:00:00 2001 From: bobsayshilol Date: Sat, 24 Apr 2021 16:46:08 +0100 Subject: [PATCH] APE: Fix typo in valLength --- taglib/ape/apetag.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/taglib/ape/apetag.cpp b/taglib/ape/apetag.cpp index 6fa9f05a..ed04c89b 100644 --- a/taglib/ape/apetag.cpp +++ b/taglib/ape/apetag.cpp @@ -419,9 +419,9 @@ void APE::Tag::parse(const ByteVector &data) } const unsigned int keyLength = nullPos - pos - 8; - const unsigned int valLegnth = data.toUInt(pos, false); + const unsigned int valLength = data.toUInt(pos, false); - if(valLegnth >= data.size() || pos > data.size() - valLegnth) { + if(valLength >= data.size() || pos > data.size() - valLength) { debug("APE::Tag::parse() - Invalid val length. Stopped parsing."); return; } @@ -439,6 +439,6 @@ void APE::Tag::parse(const ByteVector &data) debug("APE::Tag::parse() - Skipped an item due to an invalid key."); } - pos += keyLength + valLegnth + 9; + pos += keyLength + valLength + 9; } }