ffmpeg-6: fix COMPONENT_REVISION
[oi-userland.git] / components / web / firefox / patches / patch-toolkit_components_terminator_nsTerminator.cpp.patch
blob05db743123faaef0ec53a015bd0e1edad2565f7b
1 $NetBSD: patch-toolkit_components_terminator_nsTerminator.cpp,v 1.3 2019/03/19 16:11:28 ryoon Exp $
3 * Fix segfault on exit under NetBSD
5 --- firefox-102.0/toolkit/components/terminator/nsTerminator.cpp.~2~ 2022-05-31 17:22:51.266704060 +0000
6 +++ firefox-102.0/toolkit/components/terminator/nsTerminator.cpp 2022-05-31 17:32:46.773492649 +0000
7 @@ -34,7 +34,7 @@
8 #if defined(XP_WIN)
9 # include <windows.h>
10 #else
11 -# include <unistd.h>
12 +# include <time.h>
13 #endif
15 #include "mozilla/AppShutdown.h"
16 @@ -184,7 +184,10 @@
17 #if defined(XP_WIN)
18 Sleep(HEARTBEAT_INTERVAL_MS /* ms */);
19 #else
20 - usleep(HEARTBEAT_INTERVAL_MS * 1000 /* usec */);
21 + struct timespec tickd;
22 + tickd.tv_sec = 1;
23 + tickd.tv_nsec = 0;
24 + nanosleep(&tickd, NULL);
25 #endif
27 if (gHeartbeat++ < timeToLive) {