view sw/libserial/nonblock.c @ 2:a4918a161d2e

sw: starting with libserial, copied from fc-sim-sniff
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 11 Oct 2024 22:37:11 +0000
parents
children
line wrap: on
line source

/*
 * This module contains the set_serial_nonblock() function.
 */

#include <sys/types.h>
#include <sys/ioctl.h>
#include <unistd.h>

extern int target_fd;

set_serial_nonblock(state)
	int state;
{
	ioctl(target_fd, FIONBIO, &state);
}