diff options
author | Justus Winter <justus@gnupg.org> | 2017-06-19 21:20:57 +0200 |
---|---|---|
committer | Justus Winter <justus@gnupg.org> | 2017-08-05 18:42:22 +0200 |
commit | 835b293d35a209d38047126443d41fa7090daa4c (patch) | |
tree | 5bf956895e6030f91cd618fb191b2151f6d25423 /pfinet/glue-include/linux/kernel.h | |
parent | dc0b5a43224999223a246870912b0f292b1980e9 (diff) | |
download | hurd-835b293d35a209d38047126443d41fa7090daa4c.tar.gz hurd-835b293d35a209d38047126443d41fa7090daa4c.tar.bz2 hurd-835b293d35a209d38047126443d41fa7090daa4c.zip |
Use our own variant of 'assert' and 'assert_perror'.
Our variants print stack traces on failures. This will make locating
errors much easier.
Diffstat (limited to 'pfinet/glue-include/linux/kernel.h')
-rw-r--r-- | pfinet/glue-include/linux/kernel.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pfinet/glue-include/linux/kernel.h b/pfinet/glue-include/linux/kernel.h index de5852f6..62ba2ff1 100644 --- a/pfinet/glue-include/linux/kernel.h +++ b/pfinet/glue-include/linux/kernel.h @@ -3,7 +3,7 @@ #include <stdio.h> #include <stdlib.h> -#include <assert.h> +#include <assert-backtrace.h> /* These don't actually matter since our locking protocols are different. */ @@ -24,7 +24,7 @@ #define KERN_INFO #define KERN_DEBUG -#define panic(str...) (printk (str), assert (!"panic")) +#define panic(str...) (printk (str), assert_backtrace (!"panic")) /* * Display an IP address in readable format. @@ -63,14 +63,14 @@ putname (char *p) static inline int kill_proc (int pid, int signo, int priv) { - assert (signo == SIGURG); + assert_backtrace (signo == SIGURG); return 0; } static inline int kill_pg (int pgrp, int signo, int priv) { - assert (signo == SIGURG); + assert_backtrace (signo == SIGURG); return 0; } |