WiVICommandPacket: Temporarily remove GetAll

add-device-sharing
Paul Hollinsky 2022-04-26 12:58:54 -04:00
parent 2b819065ad
commit cb47065a47
1 changed files with 0 additions and 22 deletions

View File

@ -35,28 +35,6 @@ std::shared_ptr<WiVI::ResponseMessage> WiVI::CommandPacket::DecodeToMessage(cons
msg->value = setSignal.value.ValueInt32; msg->value = setSignal.value.ValueInt32;
break; break;
} }
case WiVI::Command::GetAll: {
if(bytestream.size() < sizeof(WiVI::CommandPacket::GetAll))
return {};
if(bytestream.size() != sizeof(WiVI::CommandPacket::GetAll) + header.length)
return {};
const auto& getAll = *reinterpret_cast<const WiVI::CommandPacket::GetAll*>(bytestream.data());
msg->responseTo = WiVI::Command::GetAll;
msg->info.emplace();
msg->info->sleepRequest = getAll.sleepRequest;
msg->info->connectionTimeoutMinutes = getAll.connectionTimeoutMinutes;
// Check that we have enough data for the capture infos
if(bytestream.size() < sizeof(WiVI::CommandPacket::GetAll) + (sizeof(WiVI::CaptureInfo) * getAll.numCaptureInfos))
return {};
msg->info->captures.resize(getAll.numCaptureInfos);
for(uint16_t i = 0; i < getAll.numCaptureInfos; i++)
msg->info->captures[i] = getAll.captureInfos[i];
break;
}
default: // Unknown command response default: // Unknown command response
return {}; return {};
} }