From bf904505390f24e91ad5299cf30dd69d6bd5a0c3 Mon Sep 17 00:00:00 2001 From: Tau Date: Tue, 5 Nov 2019 18:03:16 -0500 Subject: [PATCH] divahook/slider.c: Propagate HRESULT --- divahook/slider.c | 4 ++-- divahook/slider.h | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/divahook/slider.c b/divahook/slider.c index 8e7d75c4..fe114cb0 100644 --- a/divahook/slider.c +++ b/divahook/slider.c @@ -37,7 +37,7 @@ static struct uart slider_uart; static uint8_t slider_written_bytes[520]; static uint8_t slider_readable_bytes[520]; -void slider_hook_init(void) +HRESULT slider_hook_init(void) { InitializeCriticalSection(&slider_lock); @@ -47,7 +47,7 @@ void slider_hook_init(void) slider_uart.readable.bytes = slider_readable_bytes; slider_uart.readable.nbytes = sizeof(slider_readable_bytes); - iohook_push_handler(slider_handle_irp); + return iohook_push_handler(slider_handle_irp); } static HRESULT slider_handle_irp(struct irp *irp) diff --git a/divahook/slider.h b/divahook/slider.h index eb429e9a..08fe4300 100644 --- a/divahook/slider.h +++ b/divahook/slider.h @@ -1,3 +1,5 @@ #pragma once -void slider_hook_init(void); +#include + +HRESULT slider_hook_init(void);