test2.cc revision c903e3e8
1#include "EventLoop.h"
2
3muduo::EventLoop* g_loop;
4
5void threadFunc()
6{
7  g_loop->loop();
8}
9
10int main()
11{
12  muduo::EventLoop loop;
13  g_loop = &loop;
14  muduo::Thread t(threadFunc);
15  t.start();
16  t.join();
17}
18