Enforced absolute maximum read size in GDB server

This commit is contained in:
Nav
2022-11-16 23:50:28 +00:00
parent b6f3d57a04
commit 4a9e99f053
3 changed files with 26 additions and 11 deletions

View File

@@ -1,6 +1,5 @@
#include "DebugSession.hpp"
#include "src/Logger/Logger.hpp"
#include "src/EventManager/EventManager.hpp"
namespace Bloom::DebugServer::Gdb
@@ -15,7 +14,7 @@ namespace Bloom::DebugServer::Gdb
, gdbTargetDescriptor(targetDescriptor)
{
this->supportedFeatures.insert({
Feature::PACKET_SIZE, std::to_string(this->connection.getMaxPacketSize())
Feature::PACKET_SIZE, std::to_string(Connection::ABSOLUTE_MAXIMUM_PACKET_READ_SIZE)
});
EventManager::triggerEvent(std::make_shared<Events::DebugSessionStarted>());