projects
/
sbcl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
1.0.16.35: improved TIME output
[sbcl.git]
/
src
/
runtime
/
interr.c
diff --git
a/src/runtime/interr.c
b/src/runtime/interr.c
index
4ef3766
..
5f7869c
100644
(file)
--- a/
src/runtime/interr.c
+++ b/
src/runtime/interr.c
@@
-28,6
+28,7
@@
#include "genesis/static-symbols.h"
#include "genesis/vector.h"
#include "thread.h"
#include "genesis/static-symbols.h"
#include "genesis/vector.h"
#include "thread.h"
+#include "monitor.h"
\f
/* the way that we shut down the system on a fatal error */
\f
/* the way that we shut down the system on a fatal error */
@@
-37,19
+38,23
@@
default_lossage_handler(void)
exit(1);
}
static void (*lossage_handler)(void) = default_lossage_handler;
exit(1);
}
static void (*lossage_handler)(void) = default_lossage_handler;
-void
-set_lossage_handler(void handler(void))
+
+void enable_lossage_handler(void)
{
{
- lossage_handler = handler;
+ lossage_handler = monitor_or_something;
+}
+void disable_lossage_handler(void)
+{
+ lossage_handler = default_lossage_handler;
}
}
-never_returns
+void
lose(char *fmt, ...)
{
va_list ap;
fprintf(stderr, "fatal error encountered in SBCL pid %d",getpid());
#if defined(LISP_FEATURE_SB_THREAD)
lose(char *fmt, ...)
{
va_list ap;
fprintf(stderr, "fatal error encountered in SBCL pid %d",getpid());
#if defined(LISP_FEATURE_SB_THREAD)
- fprintf(stderr, "(tid %ld)",thread_self());
+ fprintf(stderr, "(tid %lu)", (unsigned long) thread_self());
#endif
if (fmt) {
fprintf(stderr, ":\n");
#endif
if (fmt) {
fprintf(stderr, ":\n");
@@
-172,6
+177,6
@@
lispobj debug_print(lispobj string)
fprintf(stderr, "%s\n",
(char *)(((struct vector *)native_pointer(string))->data));
/* shut GCC up about not using this, because that's the point.. */
fprintf(stderr, "%s\n",
(char *)(((struct vector *)native_pointer(string))->data));
/* shut GCC up about not using this, because that's the point.. */
- if (untouched);
+ (void)untouched;
return NIL;
}
return NIL;
}