4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-01-31 19:40:33 +08:00

Cygwin: posix timers: convert timer_tracker::fixup_after_fork to static method

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen 2019-01-11 20:36:46 +01:00
parent c406bea20b
commit 92cbaa9f23
2 changed files with 4 additions and 4 deletions

View File

@ -284,8 +284,8 @@ timer_tracker::clean_and_unhook ()
void void
timer_tracker::fixup_after_fork () timer_tracker::fixup_after_fork ()
{ {
hcancel = syncthread = NULL; ttstart.hcancel = ttstart.syncthread = NULL;
for (timer_tracker *tt = this; tt->next != NULL; /* nothing */) for (timer_tracker *tt = &ttstart; tt->next != NULL; /* nothing */)
{ {
timer_tracker *deleteme = tt->next; timer_tracker *deleteme = tt->next;
tt->next = deleteme->next; tt->next = deleteme->next;
@ -297,7 +297,7 @@ timer_tracker::fixup_after_fork ()
void void
fixup_timers_after_fork () fixup_timers_after_fork ()
{ {
ttstart.fixup_after_fork (); timer_tracker::fixup_after_fork ();
} }
extern "C" int extern "C" int

View File

@ -35,7 +35,7 @@ class timer_tracker
int clean_and_unhook (); int clean_and_unhook ();
DWORD thread_func (); DWORD thread_func ();
void fixup_after_fork (); static void fixup_after_fork ();
}; };
#endif /* __TIMER_H__ */ #endif /* __TIMER_H__ */