From 5df7692aa16f87ab90264644a07a18fe6f7e3d40 Mon Sep 17 00:00:00 2001 From: Scott Wheeler Date: Tue, 1 Dec 2009 12:01:43 +0000 Subject: [PATCH] pedantry++ git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@1057066 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- taglib/mpeg/id3v2/id3v2synchdata.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/taglib/mpeg/id3v2/id3v2synchdata.cpp b/taglib/mpeg/id3v2/id3v2synchdata.cpp index 2d341f13..6241751e 100644 --- a/taglib/mpeg/id3v2/id3v2synchdata.cpp +++ b/taglib/mpeg/id3v2/id3v2synchdata.cpp @@ -33,22 +33,24 @@ using namespace ID3v2; TagLib::uint SynchData::toUInt(const ByteVector &data) { uint sum = 0; - bool notsyncsafe = false; + bool notSynchSafe = false; int last = data.size() > 4 ? 3 : data.size() - 1; for(int i = 0; i <= last; i++) { - if (data[i] & 0x80) { - notsyncsafe = true; + if(data[i] & 0x80) { + notSynchSafe = true; break; } sum |= (data[i] & 0x7f) << ((last - i) * 7); } - if (notsyncsafe) { - /* Invalid data; assume this was created by some buggy software that just - * put normal integers here rather than syncsafe ones, and try it that - * way... */ + if(notSynchSafe) { + /* + * Invalid data; assume this was created by some buggy software that just + * put normal integers here rather than syncsafe ones, and try it that + * way. + */ sum = 0; for(int i = 0; i <= last; i++) sum |= data[i] << ((last - i) * 8);