From e4cc1a537a4508544bc27b072644e01feafd4e28 Mon Sep 17 00:00:00 2001 From: Martin Ling Date: Mon, 4 Nov 2013 14:02:41 +0000 Subject: [PATCH] Set data bits on Windows. --- serialport.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/serialport.c b/serialport.c index f7e946b..0ebf326 100644 --- a/serialport.c +++ b/serialport.c @@ -539,6 +539,8 @@ int sp_set_params(struct sp_port *port, int baudrate, return SP_ERR_ARG; } + dcb.ByteSize = bits; + switch (stopbits) { /* Note: There's also ONE5STOPBITS == 1.5 (unneeded so far). */ case 1: