[Qt-interest] Why Bus error clientSocket->waitForConnected()?

Kustaa Nyholm Kustaa.Nyholm at planmeca.com
Sun May 2 19:44:03 CEST 2010


> Blocking at the end of a file to wait till the year 2200
> whether a line might eventually be available doesn't make any sense.

Yes, it does not make sense to hang there, thus C getline and Java readline 
return when the end of file is reached. 


> And when there is no data currently in the receiving buffer, the sockets
> rightly so return atEnd()==true.

I don't have an opinion in this ('rightly so return atEnd()==true.') but 
this was debated in rxtx mailing list where some people argued
that it is not ok to consider it an atEnd condition if the data is
just temporarily not available. In other words the opinion was that
once eof has been reached, that is it, no more data will come.  Just
pointing it out that what is 'rightly so' for one person maybe totally
wrong for some other.

br Kusti




More information about the Qt-interest-old mailing list