From fbca73a83b236c5c86175df9f7daa285fa199243 Mon Sep 17 00:00:00 2001 From: Michael Carlberg Date: Sun, 4 Dec 2016 01:15:00 +0100 Subject: [PATCH] fix: Check ptr before accessing --- src/components/bar.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/bar.cpp b/src/components/bar.cpp index f257a201..ddb3a7dc 100644 --- a/src/components/bar.cpp +++ b/src/components/bar.cpp @@ -369,7 +369,7 @@ void bar::parse(const string& data, bool force) { m_renderer->begin(); - if (m_tray->settings().configured_slots) { + if (m_tray && m_tray->settings().configured_slots) { if (m_tray && m_tray->settings().align == alignment::LEFT) { m_renderer->reserve_space(edge::LEFT, m_tray->settings().configured_w); } else if (m_tray && m_tray->settings().align == alignment::RIGHT) {