summaryrefslogtreecommitdiff
path: root/Libraries/LibC/unistd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Libraries/LibC/unistd.cpp')
-rw-r--r--Libraries/LibC/unistd.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/Libraries/LibC/unistd.cpp b/Libraries/LibC/unistd.cpp
index cf6643e736..da88bef354 100644
--- a/Libraries/LibC/unistd.cpp
+++ b/Libraries/LibC/unistd.cpp
@@ -48,7 +48,12 @@
extern "C" {
+#ifdef NO_TLS
+static int s_cached_tid = 0;
+#else
static __thread int s_cached_tid = 0;
+#endif
+
static int s_cached_pid = 0;
int chown(const char* pathname, uid_t uid, gid_t gid)