# HG changeset patch # User Mychaela Falconia # Date 1506036653 0 # Node ID d27a890682809f4992cc4df736a2a27c38e87dda # Parent fb577c31e960dda2129f7a33c123658f623165a3 set_serial_nonblock() added to libserial diff -r fb577c31e960 -r d27a89068280 libserial-orig/Makefile --- a/libserial-orig/Makefile Thu Sep 21 23:25:02 2017 +0000 +++ b/libserial-orig/Makefile Thu Sep 21 23:30:53 2017 +0000 @@ -1,6 +1,6 @@ CC= gcc CFLAGS= -O2 -OBJS= baudtab.o openport.o setbaud.o setbyname.o +OBJS= baudtab.o nonblock.o openport.o setbaud.o setbyname.o LIB= libserial.a all: ${LIB} diff -r fb577c31e960 -r d27a89068280 libserial-orig/nonblock.c --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/libserial-orig/nonblock.c Thu Sep 21 23:30:53 2017 +0000 @@ -0,0 +1,15 @@ +/* + * This module contains the set_serial_nonblock() function. + */ + +#include +#include +#include + +extern int target_fd; + +set_serial_nonblock(state) + int state; +{ + ioctl(target_fd, FIONBIO, &state); +}