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

Unified Diff: src/trusted/service_runtime/nacl_secure_service.c

Issue 997683002: Exit cleanly for the SRPC "log" requests instead of generating crash reports. (Closed) Base URL: https://chromium.googlesource.com/native_client/src/native_client.git@master
Patch Set: Created 5 years, 9 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/trusted/service_runtime/nacl_secure_service.c
diff --git a/src/trusted/service_runtime/nacl_secure_service.c b/src/trusted/service_runtime/nacl_secure_service.c
index 9e5e315764d5c661ed34c0be7a44a654ae5d572b..3badc80e91c50a269b66c4335a44f41521d871cf 100644
--- a/src/trusted/service_runtime/nacl_secure_service.c
+++ b/src/trusted/service_runtime/nacl_secure_service.c
@@ -257,6 +257,15 @@ static void NaClSecureServiceLogRpc(
UNREFERENCED_PARAMETER(out_args);
NaClLog(5, "NaClSecureChannelLogRpc\n");
+ if (LOG_FATAL == severity) {
Mark Seaborn 2015/03/11 01:26:14 Nit: Use the NaCl style for multiline comments, wi
jvoung (off chromium) 2015/03/11 18:02:06 Done.
+ /* SRPC is deprecated and the only remaining user of this LogRpc
+ * corresponds to fairly benign errors. Also, at this point the
+ * backtraces will not be terribly interesting. Avoid spamming the
+ * crash report counter for such errors and exit cleanly.
+ */
+ NaClLog(LOG_ERROR, "%s\n", msg);
+ NaClExit(1);
Mark Seaborn 2015/03/11 01:26:14 You wrote:
jvoung (off chromium) 2015/03/11 18:02:06 I'm not sure if they are useful. For bad elf heade
+ }
NaClLog(severity, "%s\n", msg);
NaClLog(5, "NaClSecureChannelLogRpc\n");
rpc->result = NACL_SRPC_RESULT_OK;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698