diff options
author | Mathias Gumz <akira@fluxbox.org> | 2015-01-03 20:36:35 (GMT) |
---|---|---|
committer | Mathias Gumz <akira@fluxbox.org> | 2015-01-03 20:36:35 (GMT) |
commit | 60e97b968bcd712762c7ee30e350d63e4038fb63 (patch) | |
tree | 1e82972b72d764d5bb869794f30240be317c30c4 /src/FbCommands.cc | |
parent | fb7bc7380d78f5c0313ba947f746d1c9b31bd166 (diff) | |
download | fluxbox-60e97b968bcd712762c7ee30e350d63e4038fb63.zip fluxbox-60e97b968bcd712762c7ee30e350d63e4038fb63.tar.bz2 |
Fix clang warning 'expression with side effects'
Diffstat (limited to 'src/FbCommands.cc')
-rw-r--r-- | src/FbCommands.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/FbCommands.cc b/src/FbCommands.cc index c8cf4ae..10d98e7 100644 --- a/src/FbCommands.cc +++ b/src/FbCommands.cc | |||
@@ -303,8 +303,9 @@ void ShowClientMenuCmd::execute() { | |||
303 | FocusControl::Focusables::const_iterator it = list->clientList().begin(), | 303 | FocusControl::Focusables::const_iterator it = list->clientList().begin(), |
304 | it_end = list->clientList().end(); | 304 | it_end = list->clientList().end(); |
305 | for (; it != it_end; ++it) { | 305 | for (; it != it_end; ++it) { |
306 | if (typeid(**it) == typeid(FluxboxWindow) && m_pat.match(**it)) | 306 | Focusable* f = *it; |
307 | m_list.push_back(static_cast<FluxboxWindow *>(*it)); | 307 | if (typeid(*f) == typeid(FluxboxWindow) && m_pat.match(*f)) |
308 | m_list.push_back(static_cast<FluxboxWindow *>(f)); | ||
308 | } | 309 | } |
309 | 310 | ||
310 | m_menu.reset(new ClientMenu(*screen, m_list, | 311 | m_menu.reset(new ClientMenu(*screen, m_list, |
@@ -572,8 +573,9 @@ void ClientPatternTestCmd::execute() { | |||
572 | wit_end = windows->clientList().end(); | 573 | wit_end = windows->clientList().end(); |
573 | 574 | ||
574 | for ( ; wit != wit_end; wit++) { | 575 | for ( ; wit != wit_end; wit++) { |
575 | if (typeid(**wit) == typeid(FluxboxWindow) && cp->match(**wit)) { | 576 | Focusable* f = *wit; |
576 | matches.push_back(static_cast<const FluxboxWindow*>(*wit)); | 577 | if (typeid(*f) == typeid(FluxboxWindow) && cp->match(*f)) { |
578 | matches.push_back(static_cast<const FluxboxWindow*>(f)); | ||
577 | } | 579 | } |
578 | } | 580 | } |
579 | } | 581 | } |