diff options
author | Kevron Rees <kevron_m_rees@linux.intel.com> | 2013-08-13 15:56:17 -0700 |
---|---|---|
committer | Kevron Rees <kevron_m_rees@linux.intel.com> | 2013-08-13 16:00:55 -0700 |
commit | 9bc432599f5576786983315980db5d5ced48e389 (patch) | |
tree | 8a6aa2fe9aa9f593b85f09455d05665c29fb050b | |
parent | 6240721fa7a4012aca8b62e836f3a6afeccae06f (diff) | |
download | automotive-message-broker-9bc432599f5576786983315980db5d5ced48e389.tar.gz |
may have fixed memory smashing
-rw-r--r-- | ambd/pluginloader.cpp | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/ambd/pluginloader.cpp b/ambd/pluginloader.cpp index 83c56e00..6d81e1c1 100644 --- a/ambd/pluginloader.cpp +++ b/ambd/pluginloader.cpp @@ -182,8 +182,7 @@ PluginLoader::PluginLoader(string configFile, AbstractRoutingEngine* re, int arg } - json_object *pathobject = json_object_object_get(obj,"path"); - string path = string(json_object_get_string(pathobject)); + string path = configurationMap["path"]; AbstractSinkManager* plugin = loadPlugin<AbstractSinkManager*>(path, configurationMap); @@ -191,14 +190,10 @@ PluginLoader::PluginLoader(string configFile, AbstractRoutingEngine* re, int arg { throw std::runtime_error("plugin is not a SinkManager"); } - json_object_put(pathobject); - //json_object_put(obj); - } - DebugOut() << "Trying to free list" << endl; - array_list_free(sinkslist); + DebugOut() << "Trying to free obj" << endl; - //json_object_put(sinksobject); + json_object_put(sinksobject); DebugOut() << "Done" << endl; |