aboutsummaryrefslogtreecommitdiffstats
path: root/signal-composer-binding/source.cpp
diff options
context:
space:
mode:
authorRomain Forlot <romain.forlot@iot.bzh>2019-03-29 17:44:48 +0100
committerRomain Forlot <romain.forlot@iot.bzh>2019-04-02 09:07:20 +0200
commit0083a4b55b009b08d9c50c699878dcc7b8a0f0f5 (patch)
treed8bc4a4d47ee90a7c4e7a3dddf2967433fb28b6a /signal-composer-binding/source.cpp
parentfe311f49703e9691fa7d515ed84a70b996f7f3e8 (diff)
Git submodule migration to separated librariessandbox/claneys/submigration
- Replace controller binder functions definition with the binder ones. and remove the last used submodules to use the separated libraries. Bug-AGL: SPEC-2139 Change-Id: I06e5e7a03a918bf0ce139636104e1a73d2442a09 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'signal-composer-binding/source.cpp')
-rw-r--r--signal-composer-binding/source.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/signal-composer-binding/source.cpp b/signal-composer-binding/source.cpp
index a33db22..6a06b55 100644
--- a/signal-composer-binding/source.cpp
+++ b/signal-composer-binding/source.cpp
@@ -14,6 +14,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+#include <cstring>
#include "source.hpp"
#include "signal-composer.hpp"
@@ -47,6 +48,7 @@ void SourceAPI::init()
if(init_)
{
CtlSourceT source;
+ ::memset(&source, 0, sizeof(CtlSourceT));
source.uid = init_->uid;
ActionExecOne(&source, init_, json_object_new_object());
std::string sourceAPI_events = api_ + "/*";
@@ -72,7 +74,7 @@ std::string SourceAPI::api() const
/// @param[in] object - eventual data that comes with the event
/// @param[in] object - the api that subscribed the event
///
-void SourceAPI::onSourceEvents(void *closure, const char *event_name, json_object *event_obj, AFB_ApiT api)
+void SourceAPI::onSourceEvents(void *closure, const char *event_name, json_object *event_obj, afb_api_t api)
{
std::vector<std::shared_ptr<Signal>> signals { Composer::instance().searchSignals(event_name) };
@@ -129,7 +131,7 @@ void SourceAPI::onSourceEvents(void *closure, const char *event_name, json_objec
/// @param[in] object - eventual data that comes with the event
/// @param[in] object - the api that subscribed the event
///
-void SourceAPI::onSignalEvents(void *closure, const char *event_name, json_object *event_obj, AFB_ApiT api)
+void SourceAPI::onSignalEvents(void *closure, const char *event_name, json_object *event_obj, afb_api_t api)
{
Signal *sig = (Signal*) closure;
sig->onReceivedCB(event_obj);
@@ -234,7 +236,7 @@ int SourceAPI::cleanNotSubscribedSignals() {
return erased;
}
-int SourceAPI::makeSubscription(AFB_ReqT request)
+int SourceAPI::makeSubscription(afb_req_t request)
{
int err = 0;
if(getSignals_)