Adapt everything in BT5 to new capnhook API

This includes:
- Renaming of functions (iohook_invoke_next)
- Slight interface changes (com_proxy_wrap, iohook_push_handler)
- De-duplicate stuff from utils (iobuf, hr)
This commit is contained in:
icex2
2020-09-02 19:35:15 +00:00
parent b777396efd
commit 5de9fdee43
52 changed files with 265 additions and 333 deletions
+9 -3
View File
@@ -31,7 +31,13 @@ void lcd_init(void)
{
log_assert(lcd_fd == NULL);
lcd_fd = iohook_open_dummy_fd();
HRESULT hr;
hr = iohook_open_nul_fd(&lcd_fd);
if (hr != S_OK) {
log_fatal("Opening nul fd failed: %08lx", hr);
}
}
void lcd_fini(void)
@@ -49,7 +55,7 @@ lcd_dispatch_irp(struct irp *irp)
log_assert(irp != NULL);
if (irp->op != IRP_OP_OPEN && irp->fd != lcd_fd) {
return irp_invoke_next(irp);
return iohook_invoke_next(irp);
}
switch (irp->op) {
@@ -73,7 +79,7 @@ static HRESULT lcd_open(struct irp *irp)
log_assert(irp != NULL);
if (!wstr_eq(irp->open_filename, L"COM1")) {
return irp_invoke_next(irp);
return iohook_invoke_next(irp);
}
irp->fd = lcd_fd;