Skip to content

Commit

Permalink
RoutingTableRecorder: show routeProtocolData
Browse files Browse the repository at this point in the history
  • Loading branch information
ZoltanBojthe authored and levy committed Jan 16, 2024
1 parent 60c7236 commit 4ea670f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/inet/networklayer/ipv4/RoutingTableRecorder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,8 @@ void RoutingTableRecorder::recordRouteChange(cModule *host, const IRoute *route,
// action, eventNo, simtime, moduleId, routerID, dest, dest netmask, nexthop
ensureRoutingLogFileOpen();
auto ie = route->getInterface();
fprintf(routingLogFile, "%s #%" PRId64 " %ss %s %s %s/%d %s %s\n",
const cObject *routeProtocolData = route->getProtocolData();
fprintf(routingLogFile, "%s #%" PRId64 " %ss %s %s %s/%d %s %s %s\n",
tag,
getSimulation()->getEventNumber(),
SIMTIME_STR(simTime()),
Expand All @@ -158,7 +159,8 @@ void RoutingTableRecorder::recordRouteChange(cModule *host, const IRoute *route,
route->getDestinationAsGeneric().str().c_str(),
route->getPrefixLength(),
route->getNextHopAsGeneric().str().c_str(),
(ie ? ie->getInterfaceName() : "*"));
(ie ? ie->getInterfaceName() : "*"),
(routeProtocolData ? routeProtocolData->str().c_str() : ""));
fflush(routingLogFile);
}

Expand Down

0 comments on commit 4ea670f

Please sign in to comment.