Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Unified Diff: third_party/tcmalloc/chromium/src/maybe_threads.h

Issue 1715903002: Adapt upstream patches fixing potential deadlock in tcmalloc after fork. Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Updated README Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/tcmalloc/chromium/src/maybe_threads.h
diff --git a/third_party/tcmalloc/chromium/src/maybe_threads.h b/third_party/tcmalloc/chromium/src/maybe_threads.h
index 5f35e00cdf58c9527c400504d23aa47f8b6248db..bc28e5eaf513604711eb5d50c992d9d9a15ded2b 100644
--- a/third_party/tcmalloc/chromium/src/maybe_threads.h
+++ b/third_party/tcmalloc/chromium/src/maybe_threads.h
@@ -49,4 +49,11 @@ int perftools_pthread_setspecific(pthread_key_t key, void *val);
int perftools_pthread_once(pthread_once_t *ctl,
void (*init_routine) (void));
+// Our wrapper for pthread_atfork. Does _nothing_ when there are no
+// threads. See static_vars.cc:SetupAtForkLocksHandler for only user
+// of this.
+void perftools_pthread_atfork(void (*before)(),
+ void (*parent_after)(),
+ void (*child_after)());
+
#endif /* GOOGLE_MAYBE_THREADS_H_ */
« no previous file with comments | « third_party/tcmalloc/chromium/src/central_freelist.h ('k') | third_party/tcmalloc/chromium/src/maybe_threads.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698