fix: use strcmp

This commit is contained in:
Alex 2020-05-19 12:14:59 +02:00
parent 8fbaf06cbe
commit 45deb2472c
1 changed files with 1 additions and 1 deletions

View File

@ -74,7 +74,7 @@ std::thread waybar::modules::MPD::event_listener() {
dp.emit();
}
} catch (const std::exception& e) {
if (e.what() == "Connection to MPD closed") {
if (strcmp(e.what(), "Connection to MPD closed") == 0) {
spdlog::debug("{}: {}", module_name_, e.what());
} else {
spdlog::warn("{}: {}", module_name_, e.what());