Re: Tidying up comm_select.c

From: Adrian Chadd <adrian@dont-contact.us>
Date: Thu, 4 May 2000 18:57:18 +0800

On Thu, May 04, 2000, Benno Rice wrote:
> I've got a patch available at:
> http://netizen.com.au/~benno/squid-select.tar.gz
>
> which massively tidies up comm_select.c.
>
> Basically it moves all the functions that the select loop wants to call
> out of comm_select.c into comm.c, and all the functions that are
> required to implement the select loop into comm_select.c. Then I copied
> comm_select.c to comm_poll.c, and proceed to make sure that only stuff
> relevent to the select()-based implementation was in comm_select.c, and
> only poll()-related stuff went into comm_poll.c. I also added the
> beginnings of an implementation based around FreeBSD 5-CURRENT's
> kqueue()/kevent() syscalls.
>
> I've also set up configure so that it'll pick an implementation and link
> that implementation in.
>
> Comments, etc appreciated. =)
>
> PS:
> I came across two instances where read handlers were treating their fd_table
> read data as a pointer to an int and attempting to increment it, even
> though NULL was passed, or somesuch. Either way, it was causing a seg
> fault, so I commented it out for the time being. =)

Ah. I had that problem back when I was playing with a posix AIO version
of the comm/disk routines. I'll go and tidy your patch up to fix this
too, so the relevant counters get incremented correctly.

Neat work.

-- 
Adrian Chadd			Build a man a fire, and he's warm for the
<adrian@creative.net.au>	rest of the evening. Set a man on fire and
				he's warm for the rest of his life.
           Perl is Larry's gift to us - "Please Enjoy Real Life"
Received on Thu May 04 2000 - 04:57:26 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:25 MST