diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-09-16 22:06:25 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-09-16 22:06:25 +0300 |
commit | 50ecf3334aeb0a54a95672cc7bb47cfcf54021e8 (patch) | |
tree | b6ede7dda9e996ec09a35b8ba7750e4cf4078b6a /src | |
parent | 0680f936ce4be3cbd0cba338d3793d4a7782db60 (diff) | |
download | plus-50ecf3334aeb0a54a95672cc7bb47cfcf54021e8.tar.gz plus-50ecf3334aeb0a54a95672cc7bb47cfcf54021e8.tar.bz2 plus-50ecf3334aeb0a54a95672cc7bb47cfcf54021e8.tar.xz plus-50ecf3334aeb0a54a95672cc7bb47cfcf54021e8.zip |
Fix compilation warnings.
Diffstat (limited to 'src')
-rw-r--r-- | src/client.cpp | 18 | ||||
-rw-r--r-- | src/logger.cpp | 3 |
2 files changed, 6 insertions, 15 deletions
diff --git a/src/client.cpp b/src/client.cpp index 608bb5c8b..9447ce4bb 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -1355,28 +1355,18 @@ void Client::optionChanged(const std::string &name) void Client::action(const gcn::ActionEvent &event) { - bool show(false); - std::string tab = ""; + std::string tab; if (event.getId() == "Setup") - { - show = true; - } + tab = ""; else if (event.getId() == "Video") - { - show = true; tab = "Video"; - } else if (event.getId() == "Themes") - { - show = true; tab = "Theme"; - } else if (event.getId() == "Perfomance") - { - show = true; tab = "Perfomance"; - } + else + return; if (setupWindow) { diff --git a/src/logger.cpp b/src/logger.cpp index 2ec5c331e..8ce92c6d6 100644 --- a/src/logger.cpp +++ b/src/logger.cpp @@ -207,7 +207,8 @@ void Logger::error(const std::string &error_text) #elif defined __linux__ || __linux std::cerr << "Error: " << error_text << std::endl; std::string msg = "xmessage \"" + error_text + "\""; - system(msg.c_str()); + if (system(msg.c_str()) == -1) + std::cerr << "Error: " << error_text << std::endl; #else std::cerr << "Error: " << error_text << std::endl; #endif |