event/EPoll: use C++11 initializer

This commit is contained in:
Max Kellermann 2018-01-29 21:58:05 +01:00
parent ea402b765c
commit 2c65f986d6

View File

@ -33,10 +33,9 @@ class PollResultEPoll
friend class PollGroupEPoll;
std::array<epoll_event, 16> events;
size_t n_events;
public:
PollResultEPoll() : n_events(0) { }
size_t n_events = 0;
public:
size_t GetSize() const { return n_events; }
unsigned GetEvents(size_t i) const { return events[i].events; }
void *GetObject(size_t i) const { return events[i].data.ptr; }