aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormarkt <markt>2007-05-04 17:14:04 (GMT)
committermarkt <markt>2007-05-04 17:14:04 (GMT)
commit0e778b94d955a8a41cfa298cc14748914a31ec3c (patch)
treebd0df9c60e08658892a09970f22af87d0a97ea28 /src
parentf342b1758abe89b8e02905d9f31e9b766973d122 (diff)
downloadfluxbox-0e778b94d955a8a41cfa298cc14748914a31ec3c.zip
fluxbox-0e778b94d955a8a41cfa298cc14748914a31ec3c.tar.bz2
fixed infinite loop caused by deiconify command
Diffstat (limited to 'src')
-rw-r--r--src/FbCommands.cc7
-rw-r--r--src/Window.cc2
2 files changed, 6 insertions, 3 deletions
diff --git a/src/FbCommands.cc b/src/FbCommands.cc
index dae4d6a..91474b7 100644
--- a/src/FbCommands.cc
+++ b/src/FbCommands.cc
@@ -424,8 +424,11 @@ void DeiconifyCmd::execute() {
424 if (screen == 0) 424 if (screen == 0)
425 return; 425 return;
426 426
427 BScreen::Icons::reverse_iterator it= screen->iconList().rbegin(); 427 // we need to make a copy of the list of icons, or else our iterator can
428 BScreen::Icons::reverse_iterator itend= screen->iconList().rend(); 428 // become invalid
429 BScreen::Icons icon_list = screen->iconList();
430 BScreen::Icons::iterator it = icon_list.begin();
431 BScreen::Icons::iterator itend= icon_list.end();
429 unsigned int workspace_num= screen->currentWorkspaceID(); 432 unsigned int workspace_num= screen->currentWorkspaceID();
430 unsigned int old_workspace_num; 433 unsigned int old_workspace_num;
431 434
diff --git a/src/Window.cc b/src/Window.cc
index e4ade8e..cbbf7a4 100644
--- a/src/Window.cc
+++ b/src/Window.cc
@@ -466,7 +466,7 @@ void FluxboxWindow::init() {
466 466
467 restoreAttributes(); 467 restoreAttributes();
468 468
469 if (m_workspace_number < 0 || m_workspace_number >= screen().numberOfWorkspaces()) 469 if (m_workspace_number >= screen().numberOfWorkspaces())
470 m_workspace_number = screen().currentWorkspaceID(); 470 m_workspace_number = screen().currentWorkspaceID();
471 471
472 bool place_window = (m_old_pos_x == static_cast<signed>(m_screen.width())); 472 bool place_window = (m_old_pos_x == static_cast<signed>(m_screen.width()));