blob: 074f0fd4abb9668365473eecb46d51e8951133d1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
Source: https://bugzilla.mozilla.org/show_bug.cgi?id=1533969
From: Emilio Cobos Álvarez (:emilio) https://bugzilla.mozilla.org/user_profile?user_id=546716
Date: 2091-03-12 15:08 PDT
Modified for Pale Moon by: B Stack <bgstack15@gmail.com>
--- tools/profiler/tasktracer/GeckoTaskTracer.cpp.orig 2019-06-04 18:16:01.000000000 -0400
+++ tools/profiler/tasktracer/GeckoTaskTracer.cpp 2019-06-13 13:16:29.160643732 -0400
@@ -20,19 +20,19 @@
#include <stdarg.h>
-// We need a definition of gettid(), but glibc doesn't provide a
+// We need a definition of gettid(), but old glibc versions don't provide a
// wrapper for it.
#if defined(__GLIBC__)
#include <unistd.h>
#include <sys/syscall.h>
-static inline pid_t gettid()
+#define gettid() static_cast<pid_t>(syscall(SYS_gettid))
{
return (pid_t) syscall(SYS_gettid);
}
#elif defined(XP_MACOSX)
#include <unistd.h>
#include <sys/syscall.h>
-static inline pid_t gettid()
+#define gettid() static_cast<pid_t>(syscall(SYS_thread_selfid))
{
return (pid_t) syscall(SYS_thread_selfid);
}
|