From 9e295a8d193e138808931816f5858761ff08f402 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Sat, 12 Jan 2019 21:19:52 +0100 Subject: Cygwin: posix timers: implement timer_getoverrun - set DELAYTIMER_MAX to INT_MAX - make sure to set siginfo_t::si_overrun, as on Linux Signed-off-by: Corinna Vinschen --- winsup/cygwin/signal.cc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'winsup/cygwin/signal.cc') diff --git a/winsup/cygwin/signal.cc b/winsup/cygwin/signal.cc index b3e257b..74d6eb6 100644 --- a/winsup/cygwin/signal.cc +++ b/winsup/cygwin/signal.cc @@ -20,6 +20,7 @@ details. */ #include "dtable.h" #include "cygheap.h" #include "cygwait.h" +#include "timer.h" #define _SA_NORESTART 0x8000 @@ -611,6 +612,12 @@ sigwait_common (const sigset_t *set, siginfo_t *info, PLARGE_INTEGER waittime) else { _my_tls.lock (); + if (_my_tls.infodata.si_code == SI_TIMER) + { + timer_tracker *tt = (timer_tracker *) + _my_tls.infodata.si_tid; + _my_tls.infodata.si_overrun = tt->disarm_event (); + } if (info) *info = _my_tls.infodata; res = _my_tls.infodata.si_signo; -- cgit v1.1