This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: fcntl error


"aditya veer singh" <adityav@cdotd.ernet.in> writes:

> Is there any other way to get the same result as from
> fcntl(fd, F_SETFL, O_NONBLOCK) by using some other functions?

Yes, you can use ioctl(2) on socket file descriptors:

  int nonblock_enable(int fd) {
     int flag = 1;
     return ioctl(fd, FIONBIO, &flag);
  }


Regards,
-- 
Daniel Néri <daniel.neri@sigicom.se>
Sigicom AB, Stockholm, Sweden


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]