summaryrefslogtreecommitdiffhomepage
path: root/src/console
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2017-11-11 17:56:37 -0500
committermidipix <writeonce@midipix.org>2017-11-11 17:56:37 -0500
commitda425a114d4d429841a9b60f847c07f5f5697feb (patch)
tree2ee26747255aeaee358fdf728073a68bfa24ce09 /src/console
parent8cf6ce683709581138c4d66a8dbc4e8cd72b95b0 (diff)
downloadptycon-da425a114d4d429841a9b60f847c07f5f5697feb.tar.bz2
ptycon-da425a114d4d429841a9b60f847c07f5f5697feb.tar.xz
ptyc_console_writer(): properly handle leftover bytes.
Diffstat (limited to 'src/console')
-rw-r--r--src/console/ptyc_console_writer.c2
1 files changed, 1 insertions, 1 deletions
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;