main: cleanup Poller implementation
authorMarcus Fritzsch <marcus_fritzsch@mentor.com>
Fri, 30 Jun 2017 11:53:23 +0000 (13:53 +0200)
committerMarcus Fritzsch <marcus_fritzsch@mentor.com>
Tue, 8 Aug 2017 15:24:00 +0000 (17:24 +0200)
Signed-off-by: Marcus Fritzsch <marcus_fritzsch@mentor.com>
src/main.cpp

index 1359b22..e99e134 100644 (file)
@@ -20,17 +20,11 @@ struct Poller {
    std::vector<std::function<int(int)>> handlers;
    std::vector<struct pollfd> pfds;
 
-   Poller();
+   Poller() = default;
    void add_fd(int fd, std::function<int(int)> handler);
    int check_events();
 };
 
-Poller::Poller()
-   : handlers(),
-     pfds()
-{
-}
-
 void Poller::add_fd(int fd, std::function<int(int)> handler) {
    pfds.emplace_back(pollfd{ .fd = fd, .events = POLLIN, .revents = 0 });
    handlers.emplace_back(std::move(handler));