diff options
author | Niklas Haas <git@nand.wakku.to> | 2016-06-07 13:39:43 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-06-07 14:12:33 +0200 |
commit | 5b5db336e93622dc4c54e02a42a39d1b3b1a9fbd (patch) | |
tree | 884d1b3e84ff5d51879ee351bc84aaadc024ada0 /input | |
parent | 38ac5d5e7ba2e9a7234c45d431ef9b885f787a2c (diff) | |
download | mpv-5b5db336e93622dc4c54e02a42a39d1b3b1a9fbd.tar.bz2 mpv-5b5db336e93622dc4c54e02a42a39d1b3b1a9fbd.tar.xz |
build: silence -Wunused-result
For clang, it's enough to just put (void) around usages we are
intentionally ignoring the result of.
Since GCC does not seem to want to respect this decision, we are forced
to disable the warning globally.
Diffstat (limited to 'input')
-rw-r--r-- | input/ipc-unix.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/input/ipc-unix.c b/input/ipc-unix.c index 8b8a158c5f..12d7018c9e 100644 --- a/input/ipc-unix.c +++ b/input/ipc-unix.c @@ -134,7 +134,7 @@ static void *client_thread(void *p) if (fds[0].revents & POLLIN) { char discard[100]; - read(pipe_fd, discard, sizeof(discard)); + (void)read(pipe_fd, discard, sizeof(discard)); while (1) { mpv_event *event = mpv_wait_event(arg->client, 0); @@ -413,7 +413,7 @@ void mp_uninit_ipc(struct mp_ipc_ctx *arg) if (!arg) return; - write(arg->death_pipe[1], &(char){0}, 1); + (void)write(arg->death_pipe[1], &(char){0}, 1); pthread_join(arg->thread, NULL); close(arg->death_pipe[0]); |