diff options
author | Uoti Urpala <uau@mplayer2.org> | 2011-09-04 08:04:31 +0300 |
---|---|---|
committer | Uoti Urpala <uau@mplayer2.org> | 2011-09-04 08:04:31 +0300 |
commit | 79469244f72d4350b630b21eac034a81b7b24cba (patch) | |
tree | baecef33eacc73c0de1ac027ebb5fc9f9326a119 /input | |
parent | 83fc5b60046b12227540f77969b5c1aa29107bad (diff) | |
download | mpv-79469244f72d4350b630b21eac034a81b7b24cba.tar.bz2 mpv-79469244f72d4350b630b21eac034a81b7b24cba.tar.xz |
input/ar.c, input/lirc.c: fix changes missing from 1916b95b8
1916b95b8 changed two function types from returning "void" to
returning "int", but was missing changes to add "return 0;" to the
functions. Fix.
The reason for the change in the original commit was that the
functions were called through a function pointer returning int anyway,
so the missing return probably made things no more likely to fail at
runtime than they were before that commit. However, it caused a
compilation failure with clang, which treats non-void function not
returning a value as a fatal error (in GCC it's just a warning).
Diffstat (limited to 'input')
-rw-r--r-- | input/ar.c | 3 | ||||
-rw-r--r-- | input/lirc.c | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/input/ar.c b/input/ar.c index f8a3f0ad44..7b7cc8e3db 100644 --- a/input/ar.c +++ b/input/ar.c @@ -415,7 +415,7 @@ int mp_input_ar_read(void *ctx, int fd) int mp_input_ar_close(int fd) { if (initialized == 0) - return; + return 0; // Close the device. (*hidDeviceInterface)->close(hidDeviceInterface); @@ -431,6 +431,7 @@ int mp_input_ar_close(int fd) (*hidDeviceInterface)->Release(hidDeviceInterface); initialized = 0; + return 0; } #ifdef TEST diff --git a/input/lirc.c b/input/lirc.c index 80744e606a..490abe2cb1 100644 --- a/input/lirc.c +++ b/input/lirc.c @@ -119,4 +119,5 @@ int mp_input_lirc_close(int fd) cmd_buf = NULL; lirc_freeconfig(lirc_config); lirc_deinit(); + return 0; } |