X
xhoster
For file handles that don't have O_NONBLOCK turned on, I see this
behavior:
sysread will return partial reads (fewer bytes than were requested), rather
than blocking, provided that the partial read is at least one byte.
syswrite will not perform partial writes, but rather it will block waiting
for the entire write to be accepted.
Based on sysread's behavior, I would have expected syswrite to return
immediately with a partial write, provided that at least one character was
written. Why the lack of analogy between the two?
Xho
--
-------------------- http://NewsReader.Com/ --------------------
The costs of publication of this article were defrayed in part by the
payment of page charges. This article must therefore be hereby marked
advertisement in accordance with 18 U.S.C. Section 1734 solely to indicate
this fact.
behavior:
sysread will return partial reads (fewer bytes than were requested), rather
than blocking, provided that the partial read is at least one byte.
syswrite will not perform partial writes, but rather it will block waiting
for the entire write to be accepted.
Based on sysread's behavior, I would have expected syswrite to return
immediately with a partial write, provided that at least one character was
written. Why the lack of analogy between the two?
Xho
--
-------------------- http://NewsReader.Com/ --------------------
The costs of publication of this article were defrayed in part by the
payment of page charges. This article must therefore be hereby marked
advertisement in accordance with 18 U.S.C. Section 1734 solely to indicate
this fact.