system/EPollFD: rename to EpollFD

This commit is contained in:
Max Kellermann
2018-08-22 15:31:19 +02:00
parent b1390ec27f
commit dd461400fb
5 changed files with 21 additions and 21 deletions

View File

@@ -19,10 +19,10 @@
#include "config.h"
#ifdef USE_EPOLL
#include "EPollFD.hxx"
#include "EpollFD.hxx"
#include "Error.hxx"
EPollFD::EPollFD()
EpollFD::EpollFD()
:fd(::epoll_create1(EPOLL_CLOEXEC))
{
if (fd < 0)

View File

@@ -32,23 +32,23 @@ struct epoll_event;
/**
* A class that wraps Linux epoll.
*/
class EPollFD {
class EpollFD {
const int fd;
public:
/**
* Throws on error.
*/
EPollFD();
EpollFD();
~EPollFD() noexcept {
~EpollFD() noexcept {
assert(fd >= 0);
::close(fd);
}
EPollFD(const EPollFD &other) = delete;
EPollFD &operator=(const EPollFD &other) = delete;
EpollFD(const EpollFD &other) = delete;
EpollFD &operator=(const EpollFD &other) = delete;
int Wait(epoll_event *events, int maxevents, int timeout) noexcept {
return ::epoll_wait(fd, events, maxevents, timeout);