summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Spilsbury <sam.spilsbury@canonical.com>2011-08-12 20:40:51 +0800
committerSam Spilsbury <sam.spilsbury@canonical.com>2011-08-12 20:40:51 +0800
commitcb67019e078fdc9884e3fa2e84fa9b17fb0a98e6 (patch)
tree2e511efd7818d43369ab8d1dc85cc2347c146a10
parent7f81a43a28e96d8658c1ea2b9fcf9249aedd0b0d (diff)
downloadmobileperf-cb67019e078fdc9884e3fa2e84fa9b17fb0a98e6.tar.gz
mobileperf-cb67019e078fdc9884e3fa2e84fa9b17fb0a98e6.tar.bz2
memset the active window history so that we aren't jumping on unitialized garbage
in the array of windows
-rw-r--r--src/screen.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/screen.cpp b/src/screen.cpp
index f0d8601..041f583 100644
--- a/src/screen.cpp
+++ b/src/screen.cpp
@@ -4663,6 +4663,8 @@ PrivateScreen::PrivateScreen (CompScreen *screen) :
boost::bind (&PrivateScreen::handleStartupSequenceTimeout, this));
startupSequenceTimer.setTimes (1000, 1500);
+ memset (&history, 0, sizeof (Window) * ACTIVE_WINDOW_HISTORY_NUM);
+
optionSetCloseWindowKeyInitiate (CompScreen::closeWin);
optionSetCloseWindowButtonInitiate (CompScreen::closeWin);
optionSetRaiseWindowKeyInitiate (CompScreen::raiseWin);