SYNERGY-323 NO configuration available. Fix sonar "Code Smells".
This commit is contained in:
parent
60e4dc1103
commit
b542f3b302
1 changed files with 2 additions and 2 deletions
|
|
@ -61,7 +61,7 @@ ProtocolUtil::readf(synergy::IStream* stream, const char* fmt, ...)
|
||||||
catch (XIO&) {
|
catch (XIO&) {
|
||||||
result = false;
|
result = false;
|
||||||
}
|
}
|
||||||
catch (std::bad_alloc&) {
|
catch (const std::bad_alloc&) {
|
||||||
result = false;
|
result = false;
|
||||||
}
|
}
|
||||||
va_end(args);
|
va_end(args);
|
||||||
|
|
@ -473,7 +473,7 @@ UInt16 ProtocolUtil::read2BytesInt(synergy::IStream * stream)
|
||||||
std::array<UInt8, BufferSize> buffer = {};
|
std::array<UInt8, BufferSize> buffer = {};
|
||||||
read(stream, buffer.data(), BufferSize);
|
read(stream, buffer.data(), BufferSize);
|
||||||
|
|
||||||
UInt16 Result = (static_cast<UInt16>(buffer[0]) << 8) | static_cast<UInt16>(buffer[1]);
|
UInt16 Result = static_cast<UInt16>((static_cast<UInt16>(buffer[0]) << 8) | static_cast<UInt16>(buffer[1]));
|
||||||
LOG((CLOG_DEBUG2 "readf: read 2 byte integer: %d (0x%x)", Result, Result));
|
LOG((CLOG_DEBUG2 "readf: read 2 byte integer: %d (0x%x)", Result, Result));
|
||||||
|
|
||||||
return Result;
|
return Result;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue