1
// Process server for soft ioc
2
// David H. Thompson 8/29/2003
3
// Ralph Lange 04/22/2008
4
// GNU Public License (GPLv3) applies - see www.gnu.org
10
// This does I/O to stdio stdin and stdout
12
connectionItem::connectionItem(int fd, bool readonly)
16
_markedForDeletion = false;
17
_events = POLLIN|POLLPRI;
20
connectionItem::~connectionItem()
22
PRINTF("~connectionItem()\n");
24
if (_ioHandle>=0) close(_ioHandle);
27
bool connectionItem::SetPoll(struct pollfd * pfd)
29
// Do we need to be polled
30
if (_markedForDeletion || _ioHandle<1 )
32
_pfd=NULL; // This prevents OnPoll from processing
33
return false; // This prevents this item from being counted
35
// else copy the data into the poll descriptor
39
return true; // and count this in npoll
42
void connectionItem::OnWait(int pid) {}