aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2018-08-02 19:43:48 +0200
committerJosé Bollo <jose.bollo@iot.bzh>2018-08-02 19:43:48 +0200
commit3aa0f4d3c4441e45317b0c825f6a917807288947 (patch)
treee3a77fd2f6d785bd2f56c6324575a0e918aeb33d
parentde0527f7cf5b4a4278698ab034a332cf75723300 (diff)
Fix warnings and false errors
Change-Id: I434a0bd6be2758fd7964bc272d63dc280d400f47 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
-rw-r--r--src/afb-hook-flags.c2
-rw-r--r--src/afb-hook.c2
-rw-r--r--src/main-afb-daemon.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/afb-hook-flags.c b/src/afb-hook-flags.c
index 57987356..a2cb7eac 100644
--- a/src/afb-hook-flags.c
+++ b/src/afb-hook-flags.c
@@ -229,7 +229,7 @@ static char *to_text(int value, struct flags flags)
}
borrow = 0;
while (borrow != value) {
- mask = 0;
+ mask = imask = 0;
i = flags.count;
while (i) {
v = flags.flags[--i].value;
diff --git a/src/afb-hook.c b/src/afb-hook.c
index 592f92a4..3d57ca52 100644
--- a/src/afb-hook.c
+++ b/src/afb-hook.c
@@ -211,7 +211,7 @@ static void _hook_(const char *fmt1, const char *fmt2, va_list arg2, ...)
iov[4].iov_base = (void*)&chars[9];
iov[4].iov_len = 1;
- writev(2, iov, 5);
+ (void)writev(2, iov, 5);
free(mem1);
free(mem2);
diff --git a/src/main-afb-daemon.c b/src/main-afb-daemon.c
index d5d2aae2..cb362a8b 100644
--- a/src/main-afb-daemon.c
+++ b/src/main-afb-daemon.c
@@ -173,7 +173,7 @@ static void setup_daemon()
+--------------------------------------------------------- */
static void daemonize()
{
- int fd, daemon;
+ int fd = 0, daemon;
const char *output;
pid_t pid;