Re: [gnet-dev] gnet_io_channel_writen() clarification
- From: "Scott Long" <scott swiftview com>
- To: gnet-dev lists gnetlibrary org
- Subject: Re: [gnet-dev] gnet_io_channel_writen() clarification
- Date: Wed, 10 Dec 2003 10:11:40 -0800
On Tue, 09 Dec 2003 20:30:11 -0500
"David A. Helder" <dhelder gizmolabs org> wrote:
I've finally investigated this. This was delibrate. If error is
G_IO_ERROR_NONE and bytes_read/written != n, then EOF was received.
programmer should check this.
That makes sense, but the documentation strongly implies that it's
okay to leave the pointer NULL. The exact wording is: "If
bytes_writtenp is set, the number of bytes written is stored in the
integer it points to."
The word "if" causes me to think that it's optional. I'd suggest just
rewording the documentation: "bytes_writtenp points to an integer
where the number of bytes written will be stored." That makes it
clearer that it's not optional.
SwiftView, Inc. http://www.swiftview.com
] [Thread Prev