From da425a114d4d429841a9b60f847c07f5f5697feb Mon Sep 17 00:00:00 2001 From: midipix Date: Sat, 11 Nov 2017 17:56:37 -0500 Subject: ptyc_console_writer(): properly handle leftover bytes. --- src/console/ptyc_console_writer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/console/ptyc_console_writer.c b/src/console/ptyc_console_writer.c index 8621515..699d0fb 100644 --- a/src/console/ptyc_console_writer.c +++ b/src/console/ptyc_console_writer.c @@ -69,7 +69,7 @@ int __stdcall ptyc_console_writer(struct ptyc_driver_ctx_impl * ictx) /* account for leftover bytes from the previous conversion */ tctx->data.in[0] = uc_params.leftover_bytes; - uc_params.src = inbuf - uc_params.leftover_bytes; + uc_params.src = inbuf - uc_params.leftover_count; uc_params.src_size_in_bytes = iosb.info + uc_params.leftover_count; uc_params.dst = tctx->data.out; -- cgit v1.2.3