mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Fix LP#909414: Valgrind warnings in threadpool code
This commit is contained in:
@@ -138,6 +138,8 @@ my_bool my_net_init(NET *net, Vio* vio)
|
||||
net->net_skip_rest_factor= 0;
|
||||
net->last_errno=0;
|
||||
net->unused= 0;
|
||||
net->read_timeout=0;
|
||||
net->write_timeout=0;
|
||||
|
||||
if (vio != 0) /* If real connection */
|
||||
{
|
||||
|
||||
@@ -203,6 +203,7 @@ static int io_poll_create()
|
||||
int io_poll_associate_fd(int pollfd, int fd, void *data)
|
||||
{
|
||||
struct epoll_event ev;
|
||||
ev.data.u64= 0; /* Keep valgrind happy */
|
||||
ev.data.ptr= data;
|
||||
ev.events= EPOLLIN|EPOLLET|EPOLLERR|EPOLLRDHUP|EPOLLONESHOT;
|
||||
return epoll_ctl(pollfd, EPOLL_CTL_ADD, fd, &ev);
|
||||
@@ -213,6 +214,7 @@ int io_poll_associate_fd(int pollfd, int fd, void *data)
|
||||
int io_poll_start_read(int pollfd, int fd, void *data)
|
||||
{
|
||||
struct epoll_event ev;
|
||||
ev.data.u64= 0; /* Keep valgrind happy */
|
||||
ev.data.ptr= data;
|
||||
ev.events= EPOLLIN|EPOLLET|EPOLLERR|EPOLLRDHUP|EPOLLONESHOT;
|
||||
return epoll_ctl(pollfd, EPOLL_CTL_MOD, fd, &ev);
|
||||
|
||||
Reference in New Issue
Block a user