Bug 855847 - Updated console service to give more productive error message when reentrant; r=jlebar

--HG--
extra : rebase_source : 3dfbfad2f28ee12f88c1f9bf0988e0699849a662
This commit is contained in:
Dan Sharkey 2013-05-28 20:08:05 -04:00
parent 86ba0943c8
commit 790ca17fd1

View File

@ -169,7 +169,9 @@ nsConsoleService::LogMessageWithMode(nsIConsoleMessage *message, nsConsoleServic
}
if (NS_IsMainThread() && mDeliveringMessage) {
NS_WARNING("Some console listener threw an error while inside itself. Discarding this message");
NS_WARNING(nsPrintfCString("Reentrancy error: some client attempted "
"to display a message to the console while in a console listener. "
"The following message was discarded: \"%s\"", message).get())
return NS_ERROR_FAILURE;
}