]> sigrok.org Git - libsigrok.git/blobdiff - hardware/common/serial.c
demo: Free dev_contexts
[libsigrok.git] / hardware / common / serial.c
index e32c0f1e2656571f6d564e6bebd76d89f5c13aad..2980d523bbe7c39d7df0cc8860e36c8ce4dcff3b 100644 (file)
@@ -591,7 +591,10 @@ SR_PRIV int serial_set_params(struct sr_serial_dev_inst *serial, int baudrate,
 
        /* Turn off all serial port cooking. */
        term.c_iflag &= ~(ISTRIP | INLCR | ICRNL);
-       term.c_oflag &= ~(ONLCR | OCRNL | ONOCR | OFILL );
+       term.c_oflag &= ~(ONLCR | OCRNL | ONOCR);
+#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__)
+       term.c_oflag &= ~OFILL;
+#endif
 
        /* Disable canonical mode, and don't echo input characters. */
        term.c_lflag &= ~(ICANON | ECHO);