List:Commits« Previous MessageNext Message »
From:Davi Arnaut Date:December 17 2008 1:30am
Subject:Re: bzr commit into mysql-6.0 branch (vvaintroub:2681) Bug#41218
View as plain text  
Hi Vladislav,

On 12/16/08 6:55 PM, Vladislav Vaintroub wrote:
> #At file:///G:/bzr/mysql-6.0-wtf-threadpool/
>
>   2681 Vladislav Vaintroub	2008-12-16
>        Bug#41218 -  Windows port for thread pooling
>
>        * add Win32-Code subdirectory from libevent distribution
>        * add libevent library to CMake build
>        * adopt code in scheduler
>          Replace pipes that were used as communication mechanism with libevent with
>          socket pairs.  libevent cannot work with pipes on Windows - this is a
>          limitation  of Winsock's select().

OK to push. Good work, one minor comment bellow.

[..]

> +static void close_socketpair(int sock_pair[])
> +{
> +  if(sock_pair[0] != -1)
> +    closesocket(sock_pair[0]);
> +  if(sock_pair[1] != -1)
> +    closesocket(sock_pair[1]);
> +}

Since those are opened by libevent, let's use EVUTIL_CLOSESOCKET instead 
of closesocket to keep things consistent. Also, don't forget to add a 
space after the if :-)

Regards,

-- Davi Arnaut
Thread
bzr commit into mysql-6.0 branch (vvaintroub:2681) Bug#41218Vladislav Vaintroub16 Dec
  • Re: bzr commit into mysql-6.0 branch (vvaintroub:2681) Bug#41218Davi Arnaut17 Dec