mirror of
https://github.com/PabloMK7/citra
synced 2024-11-15 05:08:23 +00:00
Add nullptr check to LogEntry
Also remove explicit comparison with nullptr to make code shorter.
This commit is contained in:
parent
2b4998a122
commit
ceeb2810fe
1 changed files with 2 additions and 2 deletions
|
@ -140,7 +140,7 @@ void SetFilter(Filter* new_filter) {
|
|||
|
||||
void LogMessage(Class log_class, Level log_level, const char* filename, unsigned int line_num,
|
||||
const char* function, const char* format, ...) {
|
||||
if (filter != nullptr && !filter->CheckMessage(log_class, log_level))
|
||||
if (filter && !filter->CheckMessage(log_class, log_level))
|
||||
return;
|
||||
std::array<char, 4 * 1024> formatting_buffer;
|
||||
va_list args;
|
||||
|
@ -154,7 +154,7 @@ void LogMessage(Class log_class, Level log_level, const char* filename, unsigned
|
|||
}
|
||||
|
||||
void LogEntry(Entry& entry) {
|
||||
if (!filter->CheckMessage(entry.log_class, entry.log_level))
|
||||
if (filter && !filter->CheckMessage(entry.log_class, entry.log_level))
|
||||
return;
|
||||
|
||||
PrintColoredMessage(entry);
|
||||
|
|
Loading…
Reference in a new issue