aboutsummaryrefslogtreecommitdiff
path: root/src/core/panic.c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2016-12-22 01:05:43 -0800
committerGarrett D'Amore <garrett@damore.org>2016-12-22 01:05:43 -0800
commitb92672e20420683e73bfc017956ac6ef2b6b793b (patch)
treefb110918430e41a3751ea63801f8acb7c21b7db9 /src/core/panic.c
parent0283e8bbef80d42fda1cd9b21e4d14673c3641b8 (diff)
downloadnng-b92672e20420683e73bfc017956ac6ef2b6b793b.tar.gz
nng-b92672e20420683e73bfc017956ac6ef2b6b793b.tar.bz2
nng-b92672e20420683e73bfc017956ac6ef2b6b793b.zip
Logic for socket shutdown, cleanup, and draining figured out.
There's work to do still, but I've left clear indications of the design in comments. Some ugly mysteries are now solved.
Diffstat (limited to 'src/core/panic.c')
-rw-r--r--src/core/panic.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/core/panic.c b/src/core/panic.c
index 65eb0747..d0d6078d 100644
--- a/src/core/panic.c
+++ b/src/core/panic.c
@@ -18,9 +18,7 @@
#include "core/nng_impl.h"
-//
// Panic handling.
-//
static void
nni_show_backtrace(void)
{
@@ -44,13 +42,11 @@ nni_show_backtrace(void)
}
-//
// nni_panic shows a panic message, a possible stack bracktrace, then aborts
// the process/program. This should only be called when a condition arises
// that should not be possible, e.g. a programming assertion failure. It should
// not be called in situations such as ENOMEM, as nni_panic is fairly rude
// to any application it may be called from within.
-//
void
nni_panic(const char *fmt, ...)
{
@@ -75,6 +71,6 @@ nni_panic(const char *fmt, ...)
void
nni_println(const char *msg)
{
- /* TODO: support redirection of this later. */
+ // TODO: support redirection of this later.
nni_plat_println(msg);
}