From 11f0bc573d6f797cbc86a88d13a5d225feae764a Mon Sep 17 00:00:00 2001 From: sedrubal <dev@sedrubal.de> Date: Thu, 11 Nov 2021 19:42:27 +0100 Subject: [PATCH] Remove NS_FATAL_ERROR and stop properly? --- sim/scenarios/helper/quic-network-simulator-helper.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sim/scenarios/helper/quic-network-simulator-helper.cc b/sim/scenarios/helper/quic-network-simulator-helper.cc index 81a09cd..e74ce8d 100644 --- a/sim/scenarios/helper/quic-network-simulator-helper.cc +++ b/sim/scenarios/helper/quic-network-simulator-helper.cc @@ -20,8 +20,11 @@ using namespace ns3; void onSignal(int signum) { std::cout << "Received signal: " << signum << std::endl; // see https://gitlab.com/nsnam/ns-3-dev/issues/102 - Simulator::Stop(); - NS_FATAL_ERROR(signum); + // schedule stop task in 60s. We will exit later, when no packets arrive until then. + Simulator::Stop(Time("60s")); + // Simulator::Stop(Time("1s")); + // Simulator::Stop(); + // NS_FATAL_ERROR(signum); } void installNetDevice(Ptr<Node> node, std::string deviceName, Mac48AddressValue macAddress, Ipv4InterfaceAddress ipv4Address, Ipv6InterfaceAddress ipv6Address) { -- GitLab