summaryrefslogtreecommitdiffstats
path: root/plugins/imklog
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2007-12-20 08:54:51 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2007-12-20 08:54:51 +0000
commit2eb19201b3f4be01057c1b958a077b5fb2fce107 (patch)
tree067b64859e42ff5ad903f20ec9c22bd3600eabe6 /plugins/imklog
parent02a46ee6b0b7f326dc0affd2caae961e09bf9a3b (diff)
downloadrsyslog-2eb19201b3f4be01057c1b958a077b5fb2fce107.tar.gz
rsyslog-2eb19201b3f4be01057c1b958a077b5fb2fce107.tar.xz
rsyslog-2eb19201b3f4be01057c1b958a077b5fb2fce107.zip
- working on a potential race condition on the new input module interface.
See newsgroup posting for details on the issue: http://groups.google.com/group/comp.programming.threads/msg/330b9675f17 a1ad6 I tried some mutex operations but came to the conclusion that this does not really help. So I have now switched to plain thread cancellation, which so far seems to be OK. Need more practical experience with other input modules to make a final decision. Thus I leave all code in and have just disabled the problematic code.
Diffstat (limited to 'plugins/imklog')
-rw-r--r--plugins/imklog/imklog.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins/imklog/imklog.c b/plugins/imklog/imklog.c
index 157dee73..1c3c79c3 100644
--- a/plugins/imklog/imklog.c
+++ b/plugins/imklog/imklog.c
@@ -46,11 +46,14 @@ MODULE_TYPE_INPUT
TERM_SYNC_TYPE(eTermSync_SIGNAL)
/* Module static data */
-int dbgPrintSymbols = 0;
DEF_IMOD_STATIC_DATA
typedef struct _instanceData {
} instanceData;
+/* configuration settings TODO: move to instance data? */
+int dbgPrintSymbols = 0;
+int symbols_twice = 0;
+
/* Includes. */
#include <unistd.h>
@@ -87,12 +90,11 @@ static int kmsg,
static int use_syscall = 0,
symbol_lookup = 1;
-static char *symfile = (char *) 0,
+static char *symfile = NULL,
log_buffer[LOG_BUFFER_SIZE];
static enum LOGSRC {none, proc, kernel} logsrc;
-int symbols_twice = 0;
/* Function prototypes. */