mirror of https://github.com/tstack/lnav.git
[log_formats] ignore empty lines in non-multiline formats
This commit is contained in:
parent
623da1fe33
commit
a0986bf271
|
@ -904,6 +904,10 @@ void external_log_format::annotate(uint64_t line_number, shared_buffer_ref &line
|
|||
return;
|
||||
}
|
||||
|
||||
if (line.empty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
int pat_index = this->pattern_index_for_line(line_number);
|
||||
pattern &pat = *this->elf_pattern_order[pat_index];
|
||||
|
||||
|
|
|
@ -73,7 +73,9 @@ public:
|
|||
return *this;
|
||||
};
|
||||
|
||||
bool empty() const { return this->sb_data == nullptr; };
|
||||
bool empty() const {
|
||||
return this->sb_data == nullptr || this->sb_length == 0;
|
||||
};
|
||||
|
||||
const char *get_data() const { return this->sb_data; };
|
||||
|
||||
|
|
Loading…
Reference in New Issue