Hi, I've got a question about nsIInputStream::available...
It is documented as follows: 90 /** 91 * @return number of bytes currently available in the stream 92 */ 93 unsigned long available();
So, my question is, what does it mean for available() to return 0?
Does it indicate that at the moment, no data is available, but at a later time available() may return a number > 0?
Yes, it indicates that at the moment there is no data.
Or, does it indicate EOF?
No, it does not indicate EOF.
If the former is the case, how is it possible to detect EOF on a blocking input stream?
Call, Read and check what it returns. If it returns NS_OK and zero bytes read, then that means EOF.
-Darin _______________________________________________ Mozilla-netlib mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-netlib