Code Review
/
src
/
app-framework-binder.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
provides developper files
[src/app-framework-binder.git]
/
plugins
/
afm-main-plugin
/
afm-main-plugin.c
diff --git
a/plugins/afm-main-plugin/afm-main-plugin.c
b/plugins/afm-main-plugin/afm-main-plugin.c
index
c6408a5
..
705efcb
100644
(file)
--- a/
plugins/afm-main-plugin/afm-main-plugin.c
+++ b/
plugins/afm-main-plugin/afm-main-plugin.c
@@
-1,5
+1,5
@@
/*
/*
- * Copyright (C) 2015 "IoT.bzh"
+ * Copyright (C) 2015
, 2016
"IoT.bzh"
* Author "Fulup Ar Foll"
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Author "Fulup Ar Foll"
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@
-19,9
+19,9
@@
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
-#include <json.h>
+#include <json
-c/json
.h>
-#include
"afb-plugin.h"
+#include
<afb/afb-plugin.h>
#include "utils-jbus.h"
#include "utils-jbus.h"
@@
-62,6
+62,7
@@
static struct memo *make_memo(struct afb_req request, const char *method)
if (memo != NULL) {
memo->request = request;
memo->method = method;
if (memo != NULL) {
memo->request = request;
memo->method = method;
+ afb_req_addref(request);
}
return memo;
}
}
return memo;
}
@@
-109,6
+110,7
@@
static void embed_call_void_callback(int status, struct json_object *obj, struct
afb_req_success(memo->request, obj, NULL);
}
}
afb_req_success(memo->request, obj, NULL);
}
}
+ afb_req_unref(memo->request);
free(memo);
}
free(memo);
}
@@
-134,6
+136,7
@@
static void call_appid_callback(int status, struct json_object *obj, struct memo
obj = json_object_get(obj);
afb_req_success(memo->request, obj, NULL);
}
obj = json_object_get(obj);
afb_req_success(memo->request, obj, NULL);
}
+ afb_req_unref(memo->request);
free(memo);
}
free(memo);
}