Non-blocking socket still blocking!

Eric Norum eric at cls.usask.ca
Tue Sep 5 14:46:23 UTC 2000


"Smith, Gene" wrote:
> 
> Joel,
> When both patches are applied, I no longer block in read()!  The only thing
> I see wrong is that when I read back the flags with fctrl(F_GETFL) I see the
> value 0x1002 even though 0x4002 was the value the flags were set to. Thanks
> for the excellent help!
> 
> What is the alternate method of setting a socket non-blocking using ioctl
> that you or Eric referred to?
> 
> Enjoy your 'za!
> 

	int nonblock;

	nonblock = 1;
	ioctl (s, FIONBIO, &nonblock);
	.
	.
	.
	nonblock = 0;
	ioctl (s, FIONBIO, &nonblock);
	.
	.
	.
-- 
Eric Norum                                 eric at cls.usask.ca
Canadian Light Source                      Phone: (306) 966-6308
University of Saskatchewan                 FAX:   (306) 966-6058
Saskatoon, Canada.



More information about the users mailing list