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

Unified Diff: lib/Support/CrashRecoveryContext.cpp

Issue 939073008: Rebased PNaCl localmods in LLVM to 223109 (Closed)
Patch Set: undo localmod Created 5 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
« no previous file with comments | « lib/Makefile ('k') | lib/Support/LockFileManager.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/Support/CrashRecoveryContext.cpp
diff --git a/lib/Support/CrashRecoveryContext.cpp b/lib/Support/CrashRecoveryContext.cpp
index 9b0e44339d8411dddf387fcb3afabc7141b1a315..2eb0885610cc80fab23c11752abfcb248fc5c3b6 100644
--- a/lib/Support/CrashRecoveryContext.cpp
+++ b/lib/Support/CrashRecoveryContext.cpp
@@ -277,6 +277,7 @@ void CrashRecoveryContext::Enable() {
gCrashRecoveryEnabled = true;
+#if !defined(__native_client__) // @LOCALMOD
// Setup the signal handler.
struct sigaction Handler;
Handler.sa_handler = CrashRecoverySignalHandler;
@@ -286,6 +287,11 @@ void CrashRecoveryContext::Enable() {
for (unsigned i = 0; i != NumSignals; ++i) {
sigaction(Signals[i], &Handler, &PrevActions[i]);
}
+// @LOCALMOD-START
+#else
+#warning Cannot setup the signal handler on this machine
+#endif
+// @LOCALMOD-END
}
void CrashRecoveryContext::Disable() {
@@ -296,9 +302,11 @@ void CrashRecoveryContext::Disable() {
gCrashRecoveryEnabled = false;
+#if !defined(__native_client__) // @LOCALMOD
// Restore the previous signal handlers.
for (unsigned i = 0; i != NumSignals; ++i)
sigaction(Signals[i], &PrevActions[i], nullptr);
+#endif // @LOCALMOD
}
#endif
« no previous file with comments | « lib/Makefile ('k') | lib/Support/LockFileManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698