dovecot-2.2: log: Recent log parser change started logging "Inva...
dovecot at dovecot.org
dovecot at dovecot.org
Tue Feb 19 08:18:01 EET 2013
details: http://hg.dovecot.org/dovecot-2.2/rev/be857a95b381
changeset: 15834:be857a95b381
user: Timo Sirainen <tss at iki.fi>
date: Tue Feb 19 08:17:50 2013 +0200
description:
log: Recent log parser change started logging "Invalid log line" errors unintentionally.
diffstat:
src/log/log-connection.c | 16 +++++++---------
1 files changed, 7 insertions(+), 9 deletions(-)
diffs (34 lines):
diff -r 3ca7e0eaaf4b -r be857a95b381 src/log/log-connection.c
--- a/src/log/log-connection.c Mon Feb 18 15:14:05 2013 +0200
+++ b/src/log/log-connection.c Tue Feb 19 08:17:50 2013 +0200
@@ -201,23 +201,21 @@
}
i_failure_parse_line(line, &failure);
- if (failure.pid == 0) {
- i_error("Invalid log line: %s", line);
- return;
- }
-
switch (failure.log_type) {
case LOG_TYPE_FATAL:
case LOG_TYPE_PANIC:
- client = log_client_get(log, failure.pid);
- client->fatal_logged = TRUE;
+ if (failure.pid != 0) {
+ client = log_client_get(log, failure.pid);
+ client->fatal_logged = TRUE;
+ }
break;
case LOG_TYPE_OPTION:
log_parse_option(log, &failure);
return;
default:
- client = hash_table_lookup(log->clients,
- POINTER_CAST(failure.pid));
+ client = failure.pid == 0 ? NULL :
+ hash_table_lookup(log->clients,
+ POINTER_CAST(failure.pid));
break;
}
i_assert(failure.log_type < LOG_TYPE_COUNT);
More information about the dovecot-cvs
mailing list