dovecot-1.2: Compile fix to NetBSD: Don't use si_code which is a...
dovecot at dovecot.org
dovecot at dovecot.org
Tue Apr 7 00:15:44 EEST 2009
details: http://hg.dovecot.org/dovecot-1.2/rev/3d2a48f73f86
changeset: 8922:3d2a48f73f86
user: Timo Sirainen <tss at iki.fi>
date: Mon Apr 06 17:15:37 2009 -0400
description:
Compile fix to NetBSD: Don't use si_code which is a macro.
Patch by Tatsuyoshi.
diffstat:
2 files changed, 6 insertions(+), 6 deletions(-)
src/lib/lib-signals.c | 10 +++++-----
src/lib/lib-signals.h | 2 +-
diffs (55 lines):
diff -r d75ecf89760d -r 3d2a48f73f86 src/lib/lib-signals.c
--- a/src/lib/lib-signals.c Mon Apr 06 17:01:31 2009 -0400
+++ b/src/lib/lib-signals.c Mon Apr 06 17:15:37 2009 -0400
@@ -27,10 +27,10 @@ static bool signals_initialized = FALSE;
static bool signals_initialized = FALSE;
static struct io *io_sig = NULL;
-const char *lib_signal_code_to_str(int signo, int si_code)
+const char *lib_signal_code_to_str(int signo, int sicode)
{
/* common */
- switch (si_code) {
+ switch (sicode) {
case SI_USER:
return "kill";
#ifdef SI_KERNEL
@@ -43,7 +43,7 @@ const char *lib_signal_code_to_str(int s
switch (signo) {
case SIGSEGV:
- switch (si_code) {
+ switch (sicode) {
case SEGV_MAPERR:
return "address not mapped";
case SEGV_ACCERR:
@@ -51,7 +51,7 @@ const char *lib_signal_code_to_str(int s
}
break;
case SIGBUS:
- switch (si_code) {
+ switch (sicode) {
case BUS_ADRALN:
return "invalid address alignment";
case BUS_ADRERR:
@@ -60,7 +60,7 @@ const char *lib_signal_code_to_str(int s
return "object-specific hardware error";
}
}
- return t_strdup_printf("unknown %d", si_code);
+ return t_strdup_printf("unknown %d", sicode);
}
static void sig_handler(int signo, siginfo_t *si, void *context ATTR_UNUSED)
diff -r d75ecf89760d -r 3d2a48f73f86 src/lib/lib-signals.h
--- a/src/lib/lib-signals.h Mon Apr 06 17:01:31 2009 -0400
+++ b/src/lib/lib-signals.h Mon Apr 06 17:15:37 2009 -0400
@@ -6,7 +6,7 @@ typedef void signal_handler_t(const sigi
typedef void signal_handler_t(const siginfo_t *si, void *context);
/* Convert si_code to string */
-const char *lib_signal_code_to_str(int signo, int si_code);
+const char *lib_signal_code_to_str(int signo, int sicode);
/* Set signal handler for specific signal. If delayed is TRUE, the handler
will be called later, ie. not as a real signal handler. */
More information about the dovecot-cvs
mailing list