summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOssama Othman <ossama.othman@intel.com>2013-10-06 21:16:37 -0700
committerOssama Othman <ossama.othman@intel.com>2013-10-08 09:27:51 -0700
commit6bc8120b12fc2eff49679e3d18a9ae3054aa8399 (patch)
tree4dbe1a65246e4fa3ca9e6c22936d79c28706d7af
parent835b56b0c2067bb4f4ff177f7b46f39fc1c148ea (diff)
downloadsettings-daemon-6bc8120b12fc2eff49679e3d18a9ae3054aa8399.tar.gz
settings-daemon-6bc8120b12fc2eff49679e3d18a9ae3054aa8399.tar.bz2
settings-daemon-6bc8120b12fc2eff49679e3d18a9ae3054aa8399.zip
[manager] Return immediately on empty request.
Change-Id: Ib2b2b6743d119666757c79347a15142d94053ec1 Signed-off-by: Ossama Othman <ossama.othman@intel.com>
-rw-r--r--lib/manager.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/manager.cpp b/lib/manager.cpp
index 0b497c9..8fd64b0 100644
--- a/lib/manager.cpp
+++ b/lib/manager.cpp
@@ -105,7 +105,8 @@ ivi::settings::manager::load_settings(std::string const & dir)
* @todo I really hate catching an exception like this, but I
* really don't want to resort to a construct/init()
* style of object initialization. Fix.
- */std::cerr << "Error loading plugin: " << e.what() << "\n";
+ */
+ std::cerr << "Error loading plugin: " << e.what() << "\n";
}
}
@@ -130,6 +131,7 @@ ivi::settings::manager::dispatch(std::string request,
if (request.empty()) {
response_callback response(wsi, std::string(), std::string());
response.send_error("Empty settings request.");
+ return;
}
smart_ptr<JsonParser> const parser(json_parser_new());