 +  {
 +    LOG_SYSFATAL << "Failed in socketpair";
 +  }
++  sockets::setNonBlockAndCloseOnExec(wakeupFd_[0]);
++  sockets::setNonBlockAndCloseOnExec(wakeupFd_[1]);
 +  wakeupChannel_.reset(new Channel(this, wakeupFd_[0]));
 +
    if (t_loopInThisThread)
    {
      LOG_FATAL << "Another EventLoop " << t_loopInThisThread
-@@ -93,7 +85,8 @@ EventLoop::~EventLoop()
+@@ -93,7 +87,8 @@ EventLoop::~EventLoop()
  {
    LOG_DEBUG << "EventLoop " << this << " of thread " << threadId_
              << " destructs in thread " << CurrentThread::tid();

   t_loopInThisThread = NULL;
 }
 
@@ -108,12 +101,13 @@ void EventLoop::loop()
   while (!quit_)
   {
     activeChannels_.clear();

 
 IgnoreSigPipe initObj;
 }
@@ -69,11 +57,17 @@ EventLoop::EventLoop()
     threadId_(CurrentThread::tid()),
     poller_(Poller::newDefaultPoller(this)),
     timerQueue_(new TimerQueue(this)),
