From f04be9849356cf013f4071429f6fd152a8e5e518 Mon Sep 17 00:00:00 2001 From: Volodymyr Fialko Date: Tue, 26 Sep 2023 14:05:08 +0200 Subject: fesvr/htif: allow exit on SIGINT. Currently signal handler would call exit() only on second received signal, this prevent proper program cleanup. Instead use signal flag to exit loop. Signed-off-by: Volodymyr Fialko --- fesvr/htif.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fesvr/htif.cc b/fesvr/htif.cc index 3f93f7b..8b5eb8d 100644 --- a/fesvr/htif.cc +++ b/fesvr/htif.cc @@ -253,7 +253,7 @@ int htif_t::run() std::bind(enq_func, &fromhost_queue, std::placeholders::_1); if (tohost_addr == 0) { - while (true) + while (!signal_exit) idle(); } -- cgit v1.1