Attempt to fsync() this device returns EINVAL, causing the rfkill always to return EXIT_FAILURE when either block or unblock is requested. Simply closing the file descriptor will fix the issue. Signed-off-by: Sami Kerola <kerolasa@xxxxxx> --- sys-utils/rfkill.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys-utils/rfkill.c b/sys-utils/rfkill.c index 6b586d2ed..7914c4309 100644 --- a/sys-utils/rfkill.c +++ b/sys-utils/rfkill.c @@ -452,7 +452,7 @@ static int rfkill_block(uint8_t block, const char *param) closelog(); } free(message); - return close_fd(fd); + return close(fd); } static void __attribute__((__noreturn__)) usage(void) -- 2.14.1 -- To unsubscribe from this list: send the line "unsubscribe util-linux" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html