diff options
author | Thierry Escande <thierry.escande@linaro.org> | 2019-01-11 14:11:24 +0100 |
---|---|---|
committer | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2019-01-15 09:44:04 +0000 |
commit | 471c4808283e47ea8c957d365041454f3556ee1e (patch) | |
tree | cc652cadc0261cb3f6cdd9f6806a5decc9d018e7 /src | |
parent | ca7c77fcd3d05a1a3ab19ea998dba48aa4a0e280 (diff) |
fastrpc: Fix compilation warnings
Signed-off-by: Thierry Escande <thierry.escande@linaro.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/fastrpc_apps_user.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/fastrpc_apps_user.c b/src/fastrpc_apps_user.c index 19ea601..a3d3571 100644 --- a/src/fastrpc_apps_user.c +++ b/src/fastrpc_apps_user.c @@ -225,7 +225,7 @@ static void free_init_mem(void) { if (ginit.file) { - rpcmem_free(ginit.file); + rpcmem_free((void *)ginit.file); ginit.file = 0; } } @@ -247,10 +247,10 @@ static void create_dev(void) VERIFY(!apps_std_fopen_with_env("ADSP_LIBRARY_PATH", ";", "fastrpc_shell_0", "r", &fh)); VERIFY(!apps_std_flen(fh, &len)); VERIFY(len < INT_MAX); - ginit.file = rpcmem_alloc(0, RPCMEM_HEAP_DEFAULT, (int)len); + ginit.file = (__u64)rpcmem_alloc(0, RPCMEM_HEAP_DEFAULT, (int)len); VERIFY(ginit.file); ginit.filelen = (int)len; - VERIFY(!apps_std_fread(fh, ginit.file, len, &readlen, &eof)); + VERIFY(!apps_std_fread(fh, (void *)ginit.file, len, &readlen, &eof)); VERIFY(ginit.filelen == readlen); ginit.filefd = rpcmem_to_fd((void *)ginit.file); VERIFY(0 == ioctl(dev, FASTRPC_IOCTL_INIT_CREATE, (unsigned long)&ginit)); @@ -622,7 +622,8 @@ void deinitFileWatcher() /* Destroy the file watcher thread */ log_config_watcher.stopThread = 1; - write(log_config_watcher.event_fd, &stop, sizeof(uint64)); + if (write(log_config_watcher.event_fd, &stop, sizeof(uint64)) < 0) + perror("write"); pthread_join(log_config_watcher.thread, NULL); |