diff --git a/arch/um/os-Linux/signal.c b/arch/um/os-Linux/signal.c index 35d1b2bc00cb..4cd88b5b9006 100644 --- a/arch/um/os-Linux/signal.c +++ b/arch/um/os-Linux/signal.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include @@ -88,6 +89,8 @@ static void timer_real_alarm_handler(mcontext_t *mc) if (mc != NULL) get_regs_from_mc(®s, mc); + else + memset(®s, 0, sizeof(regs)); timer_handler(SIGALRM, NULL, ®s); }