Add cast to int to fix error when building with Qt 6
parent
7ae4c77c54
commit
0dcd6e9dfe
|
|
@ -137,7 +137,10 @@ void SunSpecModel::readNextBlockDataPart()
|
|||
{
|
||||
const auto startAddress = m_modbusStartRegister + m_partialBlockData.size();
|
||||
// Model header has length 2.
|
||||
const auto readSize = static_cast<quint16>(std::min(125, m_modelLength + 2 - m_partialBlockData.size()));
|
||||
const auto readSize = static_cast<quint16>(std::min(125, static_cast<int>(m_modelLength + 2 - m_partialBlockData.size())));
|
||||
|
||||
Still in progress?
|
||||
|
||||
|
||||
if (startAddress == m_lastStartAddress && readSize == m_lastReadSize) {
|
||||
qCWarning(dcSunSpecModelData()) << "Last read yielded no data. Not trying to read the same data again.";
|
||||
|
|
|
|||
Loading…
Reference in New Issue