[Libevent-users] API review (function prototype typo)

2006-10-31 Thread Toby Douglass
Rats... The third function API is actually this; 3. void socket_iocp_add_socket( void *socket_iocp_state, SOCKET socket, void *user_state, size_t read_buffer_size, void (*callback_function)(SOCKET socket, int event_type, void *read_buffer, DWORD byte_count, void *user_state) ); Note the change t

[Libevent-users] API review

2006-10-31 Thread Toby Douglass
Okay, I've finished off the IO completion port code. I'd appreciate feedback on the API design. There are three functions; 1. void socket_iocp_new( void **socket_iocp_state ); This function takes a pointer to a void pointer and malloc's some memory onto it. This memory holds the state for this

Re: [Libevent-users] API review

2006-10-31 Thread Toby Douglass
> Sounds interesting...what about writing data to the socket? Hmm. If an overlapped write is issued upon a IOCP'd socket, the callback function will be called when that write has completed. If I add a function to the API through which overlapped writes are issued, it will be possible to tell if

Re: [Libevent-users] API review

2006-10-31 Thread Gordon Scott
Sounds interesting...what about writing data to the socket?On 10/31/06, Toby Douglass <[EMAIL PROTECTED] > wrote:Okay, I've finished off the IO completion port code.I'd appreciate feedback on the API design. There are three functions;1. void socket_iocp_new( void **socket_iocp_state );This function