Fix issues reported by Clang Static Analyzer

Some deadcode.DeadStores.

On Debian 12:
CXXFLAGS=-I/usr/include/x86_64-linux-gnu/c++/12 \
cmake -DCMAKE_C_COMPILER=/usr/share/clang/scan-build-14/libexec/ccc-analyzer \
    -DCMAKE_CXX_COMPILER=/usr/share/clang/scan-build-14/libexec/c++-analyzer \
    -DBUILD_SHARED_LIBS=OFF \
    -DCMAKE_EXPORT_COMPILE_COMMANDS=1 \
    -DENABLE_CCACHE=ON -DBUILD_TESTING=ON -DBUILD_EXAMPLES=ON \
    -DCMAKE_BUILD_TYPE=Debug ../taglib
scan-build make
This commit is contained in:
Urs Fleisch
2023-12-07 05:00:00 +01:00
parent cf2bdce21d
commit 131918333b
12 changed files with 117 additions and 97 deletions
-1
View File
@@ -221,7 +221,6 @@ void MPC::Properties::readSV8(File *file, offset_t streamLength)
}
const unsigned short flags = data.toUShort(pos, true);
pos += 2;
d->sampleRate = sftable[(flags >> 13) & 0x07];
d->channels = ((flags >> 4) & 0x0F) + 1;