From ae442842f974202440dbc488d2ccab38624a5b3d Mon Sep 17 00:00:00 2001 From: Alex Landau Date: Thu, 15 May 2014 13:23:23 -0700 Subject: [PATCH] Make EventHandler::isPending const Summary: Because it just queries state Test Plan: fbmake Reviewed By: haijunz@fb.com Subscribers: folly@lists FB internal diff: D1332397 --- folly/io/async/EventHandler.cpp | 2 +- folly/io/async/EventHandler.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/folly/io/async/EventHandler.cpp b/folly/io/async/EventHandler.cpp index 4c9d9701..6d410de6 100644 --- a/folly/io/async/EventHandler.cpp +++ b/folly/io/async/EventHandler.cpp @@ -156,7 +156,7 @@ void EventHandler::setEventBase(EventBase* eventBase) { eventBase_ = eventBase; } -bool EventHandler::isPending() { +bool EventHandler::isPending() const { if (event_.ev_flags & EVLIST_ACTIVE) { if (event_.ev_res & EV_READ) { return true; diff --git a/folly/io/async/EventHandler.h b/folly/io/async/EventHandler.h index 3239c614..520a24c7 100644 --- a/folly/io/async/EventHandler.h +++ b/folly/io/async/EventHandler.h @@ -167,7 +167,7 @@ class EventHandler : private boost::noncopyable { return registerImpl(events, true); } - bool isPending(); + bool isPending() const; private: bool registerImpl(uint16_t events, bool internal); -- 2.34.1